Sign in to follow this  
Followers 0
Gaurang

Problem with firefox Alertbox

2 posts in this topic

hi folks,

I am using selenium to automate my application.However it is not able to handle the alertbox which pops up at page load event. So I am using autoit to click on that alertbox. I have write down the following script for that.

AutoItSetOption("WinTitleMatchMode","2")

WinWait($CmdLine[1]) 
$title = WinGetTitle($CmdLine[1]) ; retrives whole window title 
MsgBox(0,"",$title); shows the actual title
MsgBox(0,"",WinExists($title));  return 0 
MsgBox(0,"",WinKill($title)); return 0 
Send("{ENTER}") 
While WinExists($title) 
    WinActivate($title)
    Send("{ENTER}")
WEnd

MsgBox(0,"","DONE !");

Above script successfully shows the title of the window however then after other command on that fails. :)

Please let me know what the hell i am doing wrong here..

post-51475-12474910550547_thumb.jpg

Share this post


Link to post
Share on other sites



hi guys, don't know but somehow not able to edit the post so write reply..

The important thing is that problem occurs only if firefox is opened through selenium only. if I open the firefox manually it works fine.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0