Re: How to close a window using descriptive progra..
I never trust RegEx with descriptive programming.
If you're using QTP 9+, you can use the desktop utility object to get all the top-level windows, run through them, and if you find one that fits your description, close it. This way you can use complex conditions on several properties, and even RO properties (because this is done within an IF statment).
It looks something like this:
Set oDesc = Description.Create
Set oChildren = Desktop.ChildObjects(oDesc)
For i = 0 to oChildren.Count - 1
if (oChildren(i).GetROProperty("text") = "Somthing")...Continue combining conditions as needed... Then