Selenium Forum: Functional And Regression Testing Tool.
Would you like to react to this message? Create an account in a few clicks or log in to continue.
Search
Display results as :
Advanced Search
Latest topics
AEM Training | Free Online DemoWed Apr 21, 2021 5:45 pmazharuddin
c# PageFactory - issue initializing elementsFri Nov 01, 2019 8:40 pmthegoatboy
Selenium making automatic connection to random urlsMon Jul 08, 2019 12:58 pmrepairtechsolutions1
How can we design the custom framework in Selenium RCMon Jun 24, 2019 2:26 pmrandybonnettes
What are the new features in Selenium 3.0Tue Jun 18, 2019 5:37 pmpappyvicky
What are you using Selenium for? Fri Apr 12, 2019 3:52 amzhl
LIMITATIONS OF SELENIUMWed Apr 10, 2019 11:23 amswara
Navigation
 Portal
 Index
 Memberlist
 Profile
 FAQ
 Search

Go down
selenium.testing07
selenium.testing07
Regular Participant
Regular Participant
Posts : 26
Join date : 2010-11-20

How to switch another Tab of Firefox when click a link and it will open in another tab? Empty How to switch another Tab of Firefox when click a link and it will open in another tab?

Mon Dec 13, 2010 8:09 pm
Hi,
In the same case I'm getting an error "warn(1292245359123): Link has target '_blank', which is not supported in Selenium! Randomizing target to be: selenium_blank69196", when i run this code.
Some one please help me out, in this functionality. The goal is simple to move another opened tab to search some text.


This code is in C#

public void TheUntitledTest()
{
selenium.Open("/abc/static/index.html");
// selenium.WindowFocus();
selenium.Click("link=Privacy Statement");
selenium.WaitForPopUp("hello world - Mozilla Firefox", "20000");
selenium.SelectPopUp("hello world - Mozilla Firefox");
selenium.WaitForPageToLoad("30000");
for (int second = 0; ; second++)
{
if (second >= 60) Assert.Fail("timeout");
try
{
if (selenium.IsTextPresent("welcome")) break;
}
catch (Exception)
{
}
Thread.Sleep(1000);
Advisor
Advisor
------------------------
------------------------
Posts : 387
Join date : 2009-07-30
Location : India
https://seleniumforum.forumotion.net

How to switch another Tab of Firefox when click a link and it will open in another tab? Empty Re: How to switch another Tab of Firefox when click a link and it will open in another tab?

Mon Dec 13, 2010 9:58 pm
Try to make setting to open all link in new window and then switch to the window.

Tab window is not worked. In firefox tab setting setting uncheck the first option and run your code with windowfocus command to go to new window.

Try this option and sure it will help you.
selenium.testing07
selenium.testing07
Regular Participant
Regular Participant
Posts : 26
Join date : 2010-11-20

How to switch another Tab of Firefox when click a link and it will open in another tab? Empty Re: How to switch another Tab of Firefox when click a link and it will open in another tab?

Tue Dec 14, 2010 2:30 pm
Still not success, can you explain with an example?
selenium.testing07
selenium.testing07
Regular Participant
Regular Participant
Posts : 26
Join date : 2010-11-20

How to switch another Tab of Firefox when click a link and it will open in another tab? Empty Re: How to switch another Tab of Firefox when click a link and it will open in another tab?

Tue Dec 14, 2010 7:46 pm
Hi,
I search so may blogs and links,
But I did not find proper solution,
its really hack-tic. ufffffffffff Sad

Question
selenium.testing07
selenium.testing07
Regular Participant
Regular Participant
Posts : 26
Join date : 2010-11-20

How to switch another Tab of Firefox when click a link and it will open in another tab? Empty Re: How to switch another Tab of Firefox when click a link and it will open in another tab?

Tue Dec 14, 2010 11:50 pm
Hi,
I'm using Selenium.getfocus function in following way:

selenium.WindowFocus("Software Testing - Mozilla Firefox", selenium.GetTitle());

Now when I Rebuild the code error comes up:

Error 1 No overload for method 'WindowFocus' takes '2' arguments


Sponsored content

How to switch another Tab of Firefox when click a link and it will open in another tab? Empty Re: How to switch another Tab of Firefox when click a link and it will open in another tab?

Back to top
Permissions in this forum:
You cannot reply to topics in this forum