Hiya
I have two ranorex.form objects
How can i test that they are representing the same windows?
Thanks
Form Comparison
- Support Team
- Site Admin
- Posts: 12145
- Joined: Fri Jul 07, 2006 4:30 pm
- Location: Houston, Texas, USA
- Contact:
Re: Form Comparison
Hi,
what exactly do you want to automate.
Please explain your steps of automation a little more specific.
Do you have to windows opened holding the same content, or what is the us of this validation?
So please explain more precisely what you want to do.
Regards,
Tobias
Support Team
what exactly do you want to automate.
Please explain your steps of automation a little more specific.
Do you have to windows opened holding the same content, or what is the us of this validation?
So please explain more precisely what you want to do.
Regards,
Tobias
Support Team
Re: Form Comparison
Hiya
I have a Form object that represents the window i want to test
This window is a modal dialog window
However I want to also check for error dialogs when i do operations in this window
So i have a function that gets all top Form objects with same process id
Now i want to eliminate from this list the form object for the window under test
So i was thinking does the .Equals method work for Form objects
And it does, does it use all object properties to determine equality
Thanks
Clayton
I have a Form object that represents the window i want to test
This window is a modal dialog window
However I want to also check for error dialogs when i do operations in this window
So i have a function that gets all top Form objects with same process id
Now i want to eliminate from this list the form object for the window under test
So i was thinking does the .Equals method work for Form objects
And it does, does it use all object properties to determine equality
Thanks
Clayton
- Support Team
- Site Admin
- Posts: 12145
- Joined: Fri Jul 07, 2006 4:30 pm
- Location: Houston, Texas, USA
- Contact:
Re: Form Comparison
Hi,
the method Form.Equals won't fit your issues.
You have to use the internal method Element.Equals, which compares if two objects represent the same UI element.
Another way is to use a unique attribute of the form to eliminate. So you can use following path to get all the forms except the one you want to eliminate:
Regards,
Tobias
Support Team
the method Form.Equals won't fit your issues.
You have to use the internal method Element.Equals, which compares if two objects represent the same UI element.
Another way is to use a unique attribute of the form to eliminate. So you can use following path to get all the forms except the one you want to eliminate:
Code: Select all
/form[@<the_attribute_with_the_unique_value>!='<the_unique_value>']
Tobias
Support Team
Re: Form Comparison
Hiya
I think i'll use element.equals
Thanks
I think i'll use element.equals
Thanks