Expand my Community achievements bar.

SOLVED

Autopopulate Date In Table

Avatar

Level 3

Hello,

I am attempting to create a form with a table that has the date autopopulated for each row.  When I click a button using the instance manager, it will add a row, and another button will remove the most bottom row.  I am stuck now that when I add a row, it only has the date autopopulated on the top row, and not the one I just added.  I am using this Javascript to acheive the date:

if(this.rawValue == null)

{

    this.rawValue = util.printd("mmmm dd, yyyy", new Date());

}else{}  

I am wondering if anyone can shed light on why this might not be working or if this is even possible. I appreciate the help in advance. Thank you.


Justin

1 Accepted Solution

Avatar

Correct answer by
Level 10

If you want that specific datefield in each instance of your row to have a specific date you should insert that code in the initialize event of the datefield

So this way each time your datefield is initialized it will set the date automatically

View solution in original post

2 Replies

Avatar

Correct answer by
Level 10

If you want that specific datefield in each instance of your row to have a specific date you should insert that code in the initialize event of the datefield

So this way each time your datefield is initialized it will set the date automatically

Avatar

Level 3

Robert, that did it!!! Thank you!

Justin