Populate cell in repeating table by pulling the value from the ID Colum - InfoPath Dev
in

InfoPath Dev

Populate cell in repeating table by pulling the value from the ID Colum

Last post 04-19-2009 09:18 PM by ramongonzalez. 2 replies.
Page 1 of 1 (3 items)
Sort Posts: Previous Next
  • 04-19-2009 12:13 PM

    Populate cell in repeating table by pulling the value from the ID Colum

    Hi guys, I need some help, please. I have a repeating table and I need to populate a cell by pulling its value from the ID column of the form library. Why? Sometimes we need to hire the same person several times during a year and every time we signed a new contract and each one is identified by a number. How can I avoid repeating contract numbers? This is what I want to do:

    Employee 1

    Header Header Contract Number Header
        LB-001  
        LB-004  
        LB-008  

    Employee 2

    Header Header Contract Number Header
        LB-002  
        LB-003  
        LB-009  
    Until now I was able to pull the ID value to generate the employee number but the method doesn’t work with the repeating table. When I open the form the cell has a value, but when I add a second row the cell is empty.  Maybe I am using the wrong approach or maybe there is a better way to do that. Help, please. Thx!!

     

  • 04-19-2009 06:17 PM In reply to

    Re: Populate cell in repeating table by pulling the value from the ID Colum

    Hi -- how are you currently populating the cell that works correctly (on open)? Are you using a default value? Did you know that on a repeating table you can set defaults that are just used when a user inserts a row into a repeating table?

    You might want to consider setting the first contract number using an open rule. Then, when users insert new rules, you could use the first contract number as the 'seed' value for the next ones....Of course, depending on how many people are using this form at any one time, these methods have risks -- what if one person has started a form, and hasn't submitted data, and someone else starts a new form at the same time? You could end up with conflicts. In case it might help you, here is a blog post I wrote on a method for generating unique IDs using stored procedures....

    Hilary Stoupa

  • 04-19-2009 09:18 PM In reply to

    Re: Populate cell in repeating table by pulling the value from the ID Colum

    Thx for your reply.

    When the form is open, a data connection retrieves the ID value from the form library and one rule sets the cell to that number. That works. However, when I add a second row the cell is empty.

    Now I am considering using your method for generating unique IDs using stored procedures for both the employee code and the contract number.

    Thanks !!

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