Copy data from first field in the repeating table to following fields - InfoPath Dev
in

InfoPath Dev

Copy data from first field in the repeating table to following fields

Last post 04-25-2011 12:31 PM by Hilary Stoupa. 9 replies.
Page 1 of 1 (10 items)
Sort Posts: Previous Next
  • 04-22-2011 06:44 AM

    Copy data from first field in the repeating table to following fields

    Here is what I am trying to accomplish.  I have a repeating table with 50+ fields.  It is a task form that provides data to our implementers.  There are several fields that will continually be the same in all rows, but I will not know that data until the first row is filled out.  How do I ask the form to copy that field data to each added row for that particular field.I am a newbie to InfoPath and know just enough to be dangerous.  I am not a developer and I really do not write code.Is this something that can be done and if so I would much appreciate your help :-)T

     

    Newie to InfoPath!
  • 04-22-2011 03:52 PM In reply to

    • Skarn
    • Top 50 Contributor
      Male
    • Joined on 04-20-2008
    • Australia
    • Posts 198

    Re: Copy data from first field in the repeating table to following fields

    Hi Aggreen,

    On the Repeating Table Properties - Rules button - No condition - Set

    my:<field1name>  = ../my:<repeatingTablename>[1]/my:<field1name>
    my:<field2name>  = ../my:<repeatingTablename>[1]/my:<field2name>

     The above commands tell the repeating table that each time a row is added, retrieve the value of the first row ([1] part), field and assign it to the new row field.

    Hope this helps/works.

  • 04-25-2011 06:31 AM In reply to

    Re: Copy data from first field in the repeating table to following fields

    Thank you for the response.  I know I am probably being a little stupid, but I am not sure what this means.  I am adding the fields in the rules area.  Do I need to copy this code? What function is this?  Sorry for being a little slow on this.  Thank you again for your help

    Newie to InfoPath!
  • 04-25-2011 08:23 AM In reply to

    Re: Copy data from first field in the repeating table to following fields

    Skarn's reply was for using rules. Add the rule to the repeating group itself.
    Hilary Stoupa

  • 04-25-2011 09:05 AM In reply to

    Re: Copy data from first field in the repeating table to following fields

    I did, can you tell me how to by note using  the insert formula dialog box?  WHat function's do I use?

     

    Newie to InfoPath!
  • 04-25-2011 09:36 AM In reply to

    Re: Copy data from first field in the repeating table to following fields

    You'll need to manually enter the XPaths, I'm afraid. What's the name of your repeating group and field?
    Hilary Stoupa

  • 04-25-2011 09:42 AM In reply to

    Re: Copy data from first field in the repeating table to following fields

    Repeating table - Tasks

    Field Name(s): Plan Name, AIT Name and LOB

    There are three fields that need to be repeated on each row.  Is that possible?  I really appreciate the help!!!

    Newie to InfoPath!
  • 04-25-2011 11:14 AM In reply to

    Re: Copy data from first field in the repeating table to following fields

    So following Skarn's syntax, your first rule would set the PlanName field (I'm assuming there are no spaces in your field names, since they are not allowed? I'm also going to assume your fields are using the "my" namespace. You may want to right click on one, and select "Copy XPath" so you can paste the XPath in a text editor and see what it looks like) to  ../my:Tasks[1]/my:PlanName. Your second rule would set AITName = ../my:Tasks>[1]/my:AITName. Your third rule would set LOB =  ../my:Tasks>[1]/my:LOB.
    Hilary Stoupa

  • 04-25-2011 12:29 PM In reply to

    Re: Copy data from first field in the repeating table to following fields

    Thank you Thank you I get it now!  and it works!  I really appreciate it!
    Newie to InfoPath!
  • 04-25-2011 12:31 PM In reply to

    Re: Copy data from first field in the repeating table to following fields

    Oh, that's awesome! Glad you got it figured out!
    Hilary Stoupa

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