| || |
Problems with closing applications on the Windows desktop
I am conducting tests on our Windows desktop. We've got 50,000+ machines out in production and I'd like to check out the launching and closing of applications (not the app functionality itself) before we make changes in our production environment.
I am essentially testing the Windows operating system functionality.
The issue I am running into pertains to the fact that I can open a Window and close a Window (in this case a 3270 emulation window) without any issues in QTP. However, when I REOPEN the window and attempt to close it, I get an 'object not found' response, the issue arises when QTP tries to close the second window. This is despite the fact that the code is exactly the same, aside from the fact that I am launching the application once from the desktop and once from the start menu.
Does anybody have any idea why when I run virtually the same code twice, I get different results? Also, please be aware that I've only been working with QTP for about a week, so I may be missing some kind of setting. I am using QTP 8.0.
Re: Problems with closing applications on the Windows desktop
Try closing it via its handle (use the object spy to capture the 3270TE window name and replace the XXX below with the window name:
' Retrieve the window handle of the given browser
' Use that handle to reference a window object,
' then Close that object