To Repeat or Not to Repeat - InfoPath Dev
in

InfoPath Dev

To Repeat or Not to Repeat

Last post 02-27-2012 06:29 PM by Hilary Stoupa. 8 replies.
Page 1 of 1 (9 items)
Sort Posts: Previous Next
  • 02-26-2012 03:01 PM

    To Repeat or Not to Repeat

     I am considering adding a Repeating Table for our Budget InfoPath form. Our business user has a long list of different Revenue Sources, and would like to use the form to track the Budgeted Revenue and Actuals.

    I wonder whether we could have one of the repeating table's first column pre-populated, and have all the rows partially filled.

    Assumption are:

    1. we could have the Revenue Sources(Source1, Source2, source 3, source4 etc) stored in a SharePoint list

    2. users don't need to add any additional Revenue Source when they are filling the form-so we could remove the "insert item" for this specific table

    3. and each Revenue Source will be used once and only once in this Repeating Table.

    Can we do this with Secondary Data Connection without programming?


    I did some experiments and have been getting error message "Binding a non-repeating control to a repeating field or group is not supported ..."

    Thanks for your input,

     

    Wei

     

     

     

     

     

  • 02-26-2012 03:15 PM In reply to

    Re: To Repeat or Not to Repeat

     In other words, if I could make it work I would prefer a schema (RevenueSource, BudgetedRev, Actual) instead of (Source1BudgetedRev, Source1Actual; Source2BudgetedRev, Source2Actual; Source3BudgetedRev, Source3Actual; Source4BudgetedRev, Source4Actual;++++ )

  • 02-26-2012 03:43 PM In reply to

    http://debsharepoint.blogspot.com/2011/06/pre-populating-repeating-table-in.html

     http://www.bizsupportonline.net/infopath2007/how-to-prefill-infopath-repeating-table.htm

    I am working with InfoPath 2010, so the first article is closer related, BUT, when I tried to follow its instructions, the "Add another ..........Above" "Add another ......Below" menus from the Edit Default Values popup dialog were all disabled.

    Is this because I am building a web browser form? hmmm, changed my form template to a Filler form, still the same.

    On second thought the schema we get from the above approach is not that elegant either... ideally we should be able to populate one column of the Repeating table using a SharePoint list.

     

     

     

     

     


  • 02-27-2012 08:33 AM In reply to

    Re: To Repeat or Not to Repeat

    No - you should still have the ability to include multiple instances of your repeating group in the defaults, whether browser or filler - not to sound silly, but are you sure your schema is correct and you are on the repeating group when you try to add additional instances?

    Hilary Stoupa

  • 02-27-2012 01:45 PM In reply to

    Re: To Repeat or Not to Repeat

    What if instead of the defaults for the control you look at the default values for the entire form? Are the options different there? From the Data tab on the Ribbon, then the Default Values button.

    Hilary Stoupa

  • 02-27-2012 02:39 PM In reply to

     The "Add another .... Above/Below" are shown as enable using this method...


  • 02-27-2012 02:42 PM In reply to

     And only when I selected a element node that I could set its Default Value, not a Group node. See attachment


  • 02-27-2012 02:46 PM In reply to

    The Form did show up as I want it to be, but the complexity of the resulted schema made me wonder whether it is the best approach or not.The main concern/reservation I have with this Default Values solution is whenever we have a new default value, we would need to update the template and republish the template, cannot we get the default values dynamically while still no coding required?

    I will also have a closer look into the Form xml from filling such a form template.

    Thanks to Hilary for your help!!!


  • 02-27-2012 06:29 PM In reply to

    Re: To Repeat or Not to Repeat

    You are very correct in the limitation of this approach. But in InfoPath, we can't use rules to insert instances of a repeating group - which is why it takes code (or qRules, if you prefer not to write the code yourself). If it were me, I'd be using qRules - I'd have the info in a secondary data source (SharePoint list, XML file in a ShP Library, database table.... something) and then query for the data and copy it into the main data source using qRules for the user to fill out.

    Hilary Stoupa

Page 1 of 1 (9 items)
Copyright © 2003-2019 Qdabra Software. All rights reserved.
View our Terms of Use.