How can I stay and perform actions on a webpage after switching to another browser page
Hi Support,
Sometimes I need to launch two browsers and switch back and forth between the two browsers during the test, but I am having difficulty to stay on the page and perform actions after switching to another browser page. So my steps are, launch a page with a browser, firefox let's say, and then launch the same page on a different browser, iexplore for instance, then I called "Sys.Browser("firefox").BrowserWindow(0).Activate();" to switch back to firefox, and called "Aliases.browser.E5Admin.LeftNevMenu.All.HoverMouse();" to hover the mouse over a menu item, which it did, so far so good. But the next action is an link click, which TC errored out by trying to click on the link on iexplore, but I don't want it goes back to iexplore, I need it to click on the link from my currect active brwoser page. I didn't specify anything browser related when mapping the link it was clicking, so I don't understand why all the sudden it wanted to swtich back to the previous browser, plus it did perform a hovermouse action on the active browser after I switched browsers. Any suggestion how I can stay on the new active browser page and perform actions?
Thanks in advance!
Hi,
> how can I configure this temp variable on a mapped object?
You should use this variable to provide the value to the process name (or ObjectIdentifier) identification parameter for the Browser mapped object. The Page and all other page elements do not require any adjustments (assuming that they have the same structure for all target browsers).
Then, during test execution, when you need to switch to another browser, you will need to assign required value to this variable (e.g. iexplore) and, optionally, call the .RefreshMappingInfo() method to make TestComplete to refresh its internal objects cache. The necessity of the latter may be verified experimentally.
Does this help?