cancel
Showing results for 
Search instead for 
Did you mean: 

Comparing data of two elements

Former Member
0 Kudos

Hi ,

I have an application in which the user is required to fill up a form or modify an existing entry. When the user clicks on the save button I want to check if the user has made any changes or not. There are 40 odd fields in the form. I'm looking for an option other than the normal If-Then-Else.

Does someone know a better way of comparing the data in two different elements?

Are there any API's which do this?

Thanks in advance

Pradeep

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi Pradeep,

I am not sure about my soultion but you can give a try.

Check the isChanged() and isChangedByClient() API on IWDNodeElement

https://help.sap.com/javadocs/NW04S/current/wd/com/sap/tc/webdynpro/progmodel/api/IWDNodeElement.htm...

Regards, ANilkumar

Answers (2)

Answers (2)

siarhei_pisarenka3
Active Contributor
0 Kudos

Hi Pradeepkumar

Try IWDNodeElement.isChangedByClient() method.

BR

Sergei

Former Member
0 Kudos

hi,

Try out this code.

int size = wdContext.node<nodename>.size();

for(int i=0;i<size;i++)

{

if(wdContext.node<nodename>.get<nodename>ElementAt(i).isChanged())

{

<do what you want to do>

}

}

Regards,

Gopi

Former Member
0 Kudos

Hi Gopi,

How to check the same for the childnodes. Here I have one parent node and two child nodes for dropdown values. How to check is that child elements are changed or not?.