Ask a Question

Unable to find the object Sys.Browser("iexplore") is displayed.

SOLVED
Poornimak79
Occasional Contributor

Unable to find the object Sys.Browser("iexplore") is displayed.

Hi 

i am using keyword testing and recorded a script to find the below Object 

 

Sys.Browser("iexplore"). 

 

but when running system is finding the below

 

Sys.Browser("iexplore", 2) 

 

and hence erroring out.

 

can someone help me in how to handle in such cases.

 

Thank you

Poornima

  • IE
6 REPLIES 6
tristaanogre
Esteemed Contributor

Is there a reason why you're recording using Sys.Browser and not using the mapping to the page?  Basically, I have my NameMapping set up so that the Aliases.browser points to just any Browser object.

 

Basically, there are two different instances of internet explorer running in your environment.  You should also make sure you only have one instance of IE open.


Robert Martin
[Hall of Fame]
Please consider giving a Kudo if I write good stuff
----

Why automate?  I do automated testing because there's only so much a human being can do and remain healthy.  Sleep is a requirement.  So, while people sleep, automation that I create does what I've described above in order to make sure that nothing gets past the final defense of the testing group.
I love good food, good books, good friends, and good fun.

Mysterious Gremlin Master
Vegas Thrill Rider
Extensions available
Poornimak79
Occasional Contributor

thank you @tristaanogre  

 

when i tried using aliases i see the same issue.

so when checked with support was asked to use the Full name considering it to be unique.

 

there are no any instances of IE opened on the system. its in the DOM i see that .

 

please see the attached screen shot.

 

 

What happens if you kill the process in the task manager and then launch IE?  


Robert Martin
[Hall of Fame]
Please consider giving a Kudo if I write good stuff
----

Why automate?  I do automated testing because there's only so much a human being can do and remain healthy.  Sleep is a requirement.  So, while people sleep, automation that I create does what I've described above in order to make sure that nothing gets past the final defense of the testing group.
I love good food, good books, good friends, and good fun.

Mysterious Gremlin Master
Vegas Thrill Rider
Extensions available
Poornimak79
Occasional Contributor

when i do the above, in the DOM i see that 

 

Browser("iexplore", 4) 

 

 

Poornimak79
Occasional Contributor

i have killed all the process and now i see the Dom is also cleared

Can you please advise if there is a way to handle this by script

Right, because you now have no browser instance running.  So, start at the beginning... and at the end of every test, if you're going to be launching the browser in the next test, make sure you close the existing browser window.  Otherwise, make sure you detect if the browser is already running and, if it already is running, don't launch the browser.


Robert Martin
[Hall of Fame]
Please consider giving a Kudo if I write good stuff
----

Why automate?  I do automated testing because there's only so much a human being can do and remain healthy.  Sleep is a requirement.  So, while people sleep, automation that I create does what I've described above in order to make sure that nothing gets past the final defense of the testing group.
I love good food, good books, good friends, and good fun.

Mysterious Gremlin Master
Vegas Thrill Rider
Extensions available
cancel
Showing results for 
Search instead for 
Did you mean: