25-04-18 02:07 AM
27-04-18 02:50 PM
02-05-18 11:56 PM
02-05-18 11:56 PM
03-05-18 11:51 AM
03-05-18 09:39 PM
06-12-23 04:13 PM
Hi Guys,
I have faced the same issue recently, where the attribute works fine when i spied the element and next time it failed due to change in the attribute value for few SAP elements. I have found the reason for that added a logic to handle that hope this helps.
Reason - Why the attribute element changes:
My situation where I'm working with PO Tcode, as soon as i open a PO it gives 3 sections in SAP 1. Header, 2. Item Overview and 3. Item Details. All the sections are expand and collapse type elements.
When i spied an element in 1. Header section by keeping the 2 & 3 section expanded view then the attribute is giving "/app/con[0]/ses[0]/wnd[0]/usr/subSUB0:SAPLMEGUI:0013/subSUB0:SAPLMEGUI:0030/"
when i collapse section 2 & 3 that time i get " /app/con[0]/ses[0]/wnd[0]/usr/subSUB0:SAPLMEGUI:0016/subSUB0:SAPLMEGUI:0030/"
Likewise, when the other section in the SAP screen IS visible or not based on this the value of the attribute changes.
Solution:
I have found there are 3 variance for the same element and used that as dynamic value and checked using check exists in wait stage. If match found then use the same value across all the elements to interact with it.
I hope this helps you in case if you have faced similar scenario in SAP.
------------------------------
Nandhakumar C
Technology Consultant
SimplifyNext Pte Ltd
Singapore
------------------------------