Micro Focus QTP (UFT) Forums

Full Version: Page Cannot Be Displayed issue
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
I recorded a script on a web based app, when i try to replay it, i get a page cannot be displayed form, when i click refresh, the app comes up and it qtp starts to run the test. how do i get around this? I recorded myself clicking refresh but then i get a error when trying to run qtp.

Do i need to code something before the test to have it bybass the page cannot be displayed? if i go into the app manually, i dont get it, it only happens when i try to run a qtp test on the app. Like i said though, when it runs, it stops when the Page Cannot be displayed page appears but if i manually click the IE refresh button, QTP then starts the test
Have you selected Web add-in, if you have selected Web add-in then paste the code you got while recording
yes web add in is selected, the code that is generated is simply clicking refresh but when you leave the refresh code in, QTP throws an error, if take it out, the page that it starts to run on shows Page cannot be displayed, but if you manually click refresh while qtp is trying to go to the next line, the app form appears and qtp starts to run on the page like its supposed to
if you are trying to refresh with recorded one probably you wont

Use this code :

Code:
Set WshShell = CreateObject("WScript.Shell")
WshShell.SendKeys "{F5}"