<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="https://www.infopathdev.com:443/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>Newbie Questions</title><link>https://www.infopathdev.com:443/forums/39.aspx</link><description>New to InfoPath? Search to see if your question has already been answered. If it has not, then ask it here or the appropriate topic forum.</description><dc:language>en</dc:language><generator>CommunityServer 2007 SP3 (Build: 31118.962)</generator><item><title>Re: Prepopulating a repeating table in InfoPath 2007</title><link>https://www.infopathdev.com:443/forums/thread/87682.aspx</link><pubDate>Tue, 05 Mar 2013 19:46:17 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:87682</guid><dc:creator>fcoulter</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/87682.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=39&amp;PostID=87682</wfw:commentRss><description>&lt;p&gt;I should haven noticed when I first read your answer, but it looks like an InfoPath 2010 answer, not a InfoPath 2007 answer.&amp;nbsp; There is no ribbon for me to use.&lt;/p&gt;
&lt;p&gt;When I go to Default Values, I don&amp;#39;t have any options that give me a certain number of rows.&amp;nbsp; I&amp;#39;m going to go into more detail as to what I want.&lt;/p&gt;
&lt;p&gt;I want a table with X number of rows (say 50) of data.&amp;nbsp; The table should also have a header and a footer row.&amp;nbsp; I would like the table to have 8 visible columns.&amp;nbsp; The first column will be the Fiscal Year, which will start with FY 2012/13 in the first data row, and then increment by one (FY 2013/14, FY 2014/15, etc.) until I reach the end of the table.&amp;nbsp; The second through seventh column will be input columns for currency formatted integers.&amp;nbsp; The eighth column will be a calculated currency column which is the sum of the six data columns.&amp;nbsp; The footer will say Total in the first column.&amp;nbsp; The rest of the columns will be the total of all the rows above it.&lt;/p&gt;
&lt;p&gt;I suspect that I&amp;#39;ll also need two hidden columns, with the beginning and ending dates for each Fiscal Year.&amp;nbsp; I want to hide the rows that are outside the Project Start and End dates (determined earlier), which means that I&amp;#39;ll be setting up a conditional for each row based upon the beginning and ending dates.&lt;/p&gt;
&lt;p&gt;The worst possible way that I can think of to do this is to use just a normal format table, and have each row (other than the header and footer) defined as an optional section.&amp;nbsp; This would require that I define (for a 50 year grid) 350 separate data fields, plus an additional seven total fields.&amp;nbsp; (Given the limitations of functions in InfoPath 2007, each of the footer total fields will need to have something like Construction01+Construction02+Construction03+...+Contruction50 entered into their formula box.&amp;nbsp; This is doable, but seems like a lot of extra work.&lt;/p&gt;
&lt;p&gt;I&amp;#39;d like to use a repeating table, because I only need to define seven columns once (as opposed to seperately for each row), and InfoPath functions should allow for me to total the entire column simply.&amp;nbsp; Theoretically, if I had hidden columns with the start and end dates for each fiscal year, I could also set up a simple conditional formatting to hide/display the applicable rows.&lt;/p&gt;
&lt;p&gt;To make it even easier (if it&amp;#39;s doable), I&amp;#39;ve also created separately a SharePoint list with every fiscal year I could possibly want, and the Start and End Date of each year.&amp;nbsp; If I could, non-programmatically and through a data connection, read the list and create the table, life would be great.&amp;nbsp; But I can&amp;#39;t figure out how to do that, either.&amp;nbsp; When I attempt to read the list, I only get the first entry rather than a separate row for each item on the list.&lt;/p&gt;
&lt;p&gt;I&amp;#39;m stuck, and don&amp;#39;t want to hand define 357 fields, and type in 50 simple formulas and 7 real nasty ones.&amp;nbsp; (Not to mention setting up 50 separate sections with conditional formatting.)&lt;/p&gt;</description></item><item><title>Re: Prepopulating a repeating table in InfoPath 2007</title><link>https://www.infopathdev.com:443/forums/thread/87344.aspx</link><pubDate>Sat, 23 Feb 2013 00:08:32 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:87344</guid><dc:creator>Hilary Stoupa</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/87344.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=39&amp;PostID=87344</wfw:commentRss><description>&lt;p&gt;Hey, I&amp;#39;ve got no problem with elegant code, but you&amp;#39;ll have to write it and maintain it. If you are a programmer, look into &lt;a href="http://msdn.microsoft.com/en-us/library/system.xml.xpath.xpathnodeiterator.aspx"&gt;XPathNodeIterator&lt;/a&gt; and &lt;a href="http://msdn.microsoft.com/en-us/library/system.xml.xpath.xpathnavigator.aspx"&gt;XPathNavigator&lt;/a&gt; classes on MSDN to get started. &lt;/p&gt;&lt;p&gt;If one of the days changes, you can set the fields in the repeating group to blank (assuming the start and end date are outside of the repeating group) but it will set ALL of them. Not just the ones affected.&lt;/p&gt;&lt;p&gt;&lt;a href="http://www.infopathdev.com/blogs/hilary/archive/2009/06/07/hack-manifest-xsf-to-filter-the-target-of-a-rule.aspx"&gt;Here&amp;#39;s&lt;/a&gt; a blog post on filtering the target of a rule by manually modifying the manifest, if you choose to go a non-code route. You might also want to look at &lt;a href="http://www.qdabra.com/en/products/qRules_new.aspx"&gt;qRules&lt;/a&gt;, which would give you flexibility of code w/out you having to write your own, and could handle this logic easily, so you wouldn&amp;#39;t have to take the default data path.&lt;/p&gt;</description></item><item><title>Re: Prepopulating a repeating table in InfoPath 2007</title><link>https://www.infopathdev.com:443/forums/thread/87342.aspx</link><pubDate>Fri, 22 Feb 2013 23:38:01 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:87342</guid><dc:creator>fcoulter</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/87342.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=39&amp;PostID=87342</wfw:commentRss><description>&lt;p&gt;I like it, except it&amp;#39;s hardly elegent.&amp;nbsp; (I was brought up in the bad days, when code had to be elegent.&amp;nbsp; Developed bad habits.)&lt;/p&gt;&lt;p&gt;Is there a way to zero out the data columns in the hidden rows?&amp;nbsp; I&amp;#39;m considering the possibiity that data is entered in a row, and then one of the days changes, hiding the row.&lt;/p&gt;</description></item><item><title>Re: Prepopulating a repeating table in InfoPath 2007</title><link>https://www.infopathdev.com:443/forums/thread/87339.aspx</link><pubDate>Fri, 22 Feb 2013 23:17:57 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:87339</guid><dc:creator>Hilary Stoupa</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/87339.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=39&amp;PostID=87339</wfw:commentRss><description>&lt;p&gt;How many rows does the table in the form need to be? Simply as many years as are between start and end date?&lt;/p&gt;&lt;p&gt;You could just use default data for this and some conditional formatting. Makes for slightly messy and bigger XML files, but the most rows you&amp;#39;d have is 86 or 87, so that isn&amp;#39;t too terrible.&lt;/p&gt;&lt;p&gt;Under the Data tab in the ribbon, look for default values. Set your repeating group to contain 87 rows by default. This will take a lot of clicking.&lt;/p&gt;&lt;p&gt;You can set the date value for each row in the default data.&lt;/p&gt;&lt;p&gt;Then hide the rows if the Start or End are blank. And hide the rows if they are out of the range for the Start and End. Not elegant, but no code needed.&lt;/p&gt;&lt;p&gt;And if Start or End date change, just set the columns that aren&amp;#39;t your prefilled date to blank so that the form doesn&amp;#39;t have junk hidden data floating around where the user can&amp;#39;t see it.&lt;/p&gt;</description></item><item><title>Prepopulating a repeating table in InfoPath 2007</title><link>https://www.infopathdev.com:443/forums/thread/87338.aspx</link><pubDate>Fri, 22 Feb 2013 23:08:59 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:87338</guid><dc:creator>fcoulter</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/87338.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=39&amp;PostID=87338</wfw:commentRss><description>&lt;p&gt;I&amp;#39;ve been wracking my brain trying to do this without code, but have failed.&amp;nbsp; So I&amp;#39;m here, asking for help.&amp;nbsp; (If it can only be done through code, VB would be preferable.&amp;nbsp;But beggars can&amp;#39;t be choosers.)&lt;/p&gt;&lt;p&gt;I am attempting to create a repeating table with a specific number of rows.&amp;nbsp; In the first column of the repeating table must be certain text.&amp;nbsp; The information to generate the rows is contained elsewhere on the form.&lt;/p&gt;&lt;p&gt;Specifically, the form contains two date fields: StartDate and EndDate.&amp;nbsp; StartDate can be no earlier than today, and no later than 9/30/2099.&amp;nbsp; EndDate can be no earlier than StartDate and no later than 9/30/2099.&lt;/p&gt;&lt;p&gt;Those dates must be converted to a fiscal year format.&amp;nbsp; The organization uses an October 1 - September 30 fiscal year, so I can create a fiscal year through a whole crapload of nested functions, but I&amp;#39;m not sure if this gets me anywhere.&amp;nbsp;Any date between 10/1/20xx and 9/30/20yy (with yy = xx+1) is in FY20xx/yy.&amp;nbsp; (You can calculate the yy by adding 92 days to the day in the field, then grabbing just the last two digits of the year.&amp;nbsp; Then xx is just one less than yy.)&lt;/p&gt;&lt;p&gt;I would like the first data row of the table to have in the first column the fiscal year of the StartDate.&amp;nbsp; Then, each row following would have the fiscal year incremented by one until the last row has the fiscal year of the EndDate.&amp;nbsp; If StartDate and EndDate are in the same fiscal year, then there would only be one row.&lt;/p&gt;&lt;p&gt;I have wracked my brain trying to figure out how to do this in InfoPath, and have failed.&amp;nbsp; Any help would be appreciated.&lt;/p&gt;&lt;p&gt;On a (simpler) related note, is there an easy way to reset a repeating table, dropping all existing data?&amp;nbsp; This code would be called prior to running the above code IF the StartDate or EndDate are changed, prior to regenerating the table.&lt;/p&gt;&lt;p&gt;Not that it matters, but the other columns are for entering requested budget amounts, by year.&lt;/p&gt;</description></item></channel></rss>