Forum Discussion
You can use the restore and position functions to resize the browser window.
Ex:
//JScript
Sys.Browser("chrome").BrowserWindow(0).Restore();
Sys.Browser("chrome").BrowserWindow(0).Position(0, 0, 800, 600);
- Rodrigo2010 years agoContributor
Thank you very much!
But I would like to know, and to set the resolution using the GUI of TestComplete instead of using the script part, how could I do that?
- Marsha_R10 years agoChampion Level 3
The TestComplete project properties only have controls for the TestComplete UI.
To make the browser resolution change manually, you can change it from your browser before you run the test.
If I was doing it and I didn't want to call Ryan's script from every test, then I would make a master test that calls all the other tests and put Ryan's at the top and bottom of that.
You could also just run Ryan's script manually at the beginning of your test and at the end, which would still give you control over it but avoid having to build a master test.
- TanyaYatskovska10 years agoSmartBear Alumni (Retired)
Hi Rodrigo20,
Ryan’s suggestion can do the trick. I wanted to add that perhaps using virtual browsers will work for your task. Originally, it’s designed to test web applications on mobile devices where mobile windows can be different. Please read the following article for details: http://smartbear.com/viewarticle/56249/
Related Content
- 8 years agoSundaytwins
Recent Discussions
- 7 minutes agoSubhraDas