How to make objects index dynamic
Hi,
I have two applications which performs same fuctions. I have same script for these two applications.
The only difference in these aplications is one more screen is Added in say app 2.
My code is as follows:-
App 1 with one extra screen:-
Sys.Process("abc").SWTObject("Shell", "PCW").SWTObject("Composite", "").SWTObject("Composite", "").SWTObject("Composite", "", 1).SWTObject("Composite", "", 1).SWTObject("Composite", "", 4).SWTObject("PCC", "").SWTObject("Button", "Validate", 3)
App 2:-
Sys.Process("xyz").SWTObject("Shell", "PCW").SWTObject("Composite", "").SWTObject("Composite", "").SWTObject("Composite", "", 1).SWTObject("Composite", "", 1).SWTObject("Composite", "", 3).SWTObject("PCC", "").SWTObject("Button", "Validate", 3)
How to make this one dynamic, so my script will run on both app with same index?
Thanks in Advance.
Use a "*" (wildcard) for the index of the part that changes.
Assuming you have them mapped.
And you're using that index as an idenfication property.