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.
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
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: