82
Views
9
Comments
Solved
Copy last row Editable Table Widget - Function Duplicate

Hi,


In the Editable Table widget, how can I make a button duplicate that same row? I have a this button (image attached)


Regards,


Rank: #88
Solution

Hi Josep,

I think you want this of functionality. See demo with below Link-

Copy Row


1. Create a action for Row Copy and take one input variable for current row number

2. Take similar entity type local variable 

3. use List append and list append all for that


Note- Row copy on run time so you want keep data in entity you need to use action for create or update accordingly.


Hope this will Help you

Regards

Rahul Sahu

CopyRow.oml

Thanks, but... and if the table takes an aggregate with several tables, how would it be?


Regards!

Rank: #88

Josep Chaqués Ojeda wrote:

Thanks, but... and if the table takes an aggregate with several tables, how would it be?


Regards!

 

 Hi Josep,

Than create a local variable same list data type .like below image

Regards

Rahul Sahu

Yes, I got it right:



And the Screen Action: 


But I keep getting the error...


Regards.


Rank: #88

Josep Chaqués Ojeda wrote:

Yes, I got it right:



And the Screen Action: 


But I keep getting the error...


Regards.


  What error you getting? please post.

Rahul Sahu wrote:

Josep Chaqués Ojeda wrote:

Yes, I got it right:



And the Screen Action: 


But I keep getting the error...


Regards.


  What error you getting? please post.

Is working!


Thank you!


Regards,


 

Hi,


One question:


In this case of duplicating records, how could you validate that saving (a different button) has changed a field in the list of records? (that is, what you have duplicated is not the same)


Regards,

Rank: #88

Josep Chaqués Ojeda wrote:

Hi,


One question:


In this case of duplicating records, how could you validate that saving (a different button) has changed a field in the list of records? (that is, what you have duplicated is not the same)


Regards,

 Hi Josep,

You need to create logic for that or just you can create unique index on Entity column.

so duplicate record will not insert.


Regards

Rahul Sahu