[wtr-general] Re: Has anyone tried using AutoIt to handle unexpected Popup windows

2009-10-21 Thread Željko Filipin
On Wed, Oct 21, 2009 at 9:59 AM, Pallavi Sharma write2pall...@gmail.com
wrote:
 as WinWait REGEXPTITLE:.* but it doesn't work.

When I was playing with autoit, I vaguely remember that regular expressions
worked only if I had full Autoit installed on the machine. Watir installs
only subset of Autoit functionality, and I think regular expressions are not
supported there. Try installing Autoit, it should fix it.

Željko
--
http://watirpodcast.com/

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Watir General group.
To post to this group, send email to watir-general@googlegroups.com
Before posting, please read the following guidelines: 
http://wiki.openqa.org/display/WTR/Support
To unsubscribe from this group, send email to 
watir-general-unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/watir-general
-~--~~~~--~~--~--~---



[wtr-general] Re: Has anyone tried using AutoIt to handle unexpected Popup windows

2009-10-21 Thread Pallavi Sharma
I have full installed AutoIT on my system Zeljko, still this doesn't work.
Sharing the page and the script.

I have used two methods to handle unexpected popups, winclicker and autoit

I used with winclicker windowtitle as // it didn't worked

with auto it REGEXPTITLE:.* it also didn't worked.


Please let me know about it.

The script runs from command line HandlePopup.rb windowtitle Buttontext
Timeout




On Wed, Oct 21, 2009 at 1:51 PM, Željko Filipin 
zeljko.fili...@wa-research.ch wrote:

 On Wed, Oct 21, 2009 at 9:59 AM, Pallavi Sharma write2pall...@gmail.com
 wrote:
  as WinWait REGEXPTITLE:.* but it doesn't work.

 When I was playing with autoit, I vaguely remember that regular expressions
 worked only if I had full Autoit installed on the machine. Watir installs
 only subset of Autoit functionality, and I think regular expressions are not
 supported there. Try installing Autoit, it should fix it.

 Željko
 --
 http://watirpodcast.com/


 


--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Watir General group.
To post to this group, send email to watir-general@googlegroups.com
Before posting, please read the following guidelines: 
http://wiki.openqa.org/display/WTR/Support
To unsubscribe from this group, send email to 
watir-general-unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/watir-general
-~--~~~~--~~--~--~---










HandlePopUp.rb
Description: Binary data


[wtr-general] Re: Has anyone tried using AutoIt to handle unexpected Popup windows

2009-10-21 Thread Željko Filipin
On Wed, Oct 21, 2009 at 10:46 AM, Pallavi Sharma write2pall...@gmail.com
wrote:
 I have full installed AutoIT on my system Zeljko, still this doesn't work.

Did you ask at Autoit forum? This sounds to me like Autoit problem, not
really Watir related.

Željko

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Watir General group.
To post to this group, send email to watir-general@googlegroups.com
Before posting, please read the following guidelines: 
http://wiki.openqa.org/display/WTR/Support
To unsubscribe from this group, send email to 
watir-general-unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/watir-general
-~--~~~~--~~--~--~---



[wtr-general] Re: Has anyone tried using AutoIt to handle unexpected Popup windows

2009-10-21 Thread Pallavi Sharma
I know, i am going to ask there. I know its not a watir issue, just
wondering whether someone ever tried this here in this forum.
recovery scenarios are a part of any automation framework.

I will try again and if i get a solution will post it here for further help.

On Wed, Oct 21, 2009 at 2:21 PM, Željko Filipin 
zeljko.fili...@wa-research.ch wrote:

 On Wed, Oct 21, 2009 at 10:46 AM, Pallavi Sharma write2pall...@gmail.com
 wrote:
  I have full installed AutoIT on my system Zeljko, still this doesn't
 work.

 Did you ask at Autoit forum? This sounds to me like Autoit problem, not
 really Watir related.

 Željko


 


--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Watir General group.
To post to this group, send email to watir-general@googlegroups.com
Before posting, please read the following guidelines: 
http://wiki.openqa.org/display/WTR/Support
To unsubscribe from this group, send email to 
watir-general-unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/watir-general
-~--~~~~--~~--~--~---



[wtr-general] Re: Has anyone tried using AutoIt to handle unexpected Popup windows

2009-10-21 Thread Ankur Gera
Hi Pallavi,

Try to use the code which i provided for handling pop-up's through AutoIt.

Thanks  Regards,
Ankur Gera
TCS

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Watir General group.
To post to this group, send email to watir-general@googlegroups.com
Before posting, please read the following guidelines: 
http://wiki.openqa.org/display/WTR/Support
To unsubscribe from this group, send email to 
watir-general-unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/watir-general
-~--~~~~--~~--~--~---



[wtr-general] Re: Has anyone tried using AutoIt to handle unexpected Popup windows

2009-10-21 Thread Ankur Gera
Hi Pallavi,

Below is the respective code :-

require 'watir'
require 'win32ole'

#Supply AutoItX3 as an argument to the constructor of WIN32OLE
#for handling pop-up windows using WIN32OLE objects.WIN32OLE will act as an
interface
#for handling pop-up windows using AutoItX3 functions.
ai = WIN32OLE.new(AutoItX3.Control)

#New IE Browser window
ie=Watir::IE.new

#Go to AutoIt website
ie.goto(http://www.autoitscript.com/autoit3/downloads.shtml;)

#Click Download AutoIt image
ie.image(:src,/download_autoit/).click_no_wait


#Wait for the pop-up window with the specified title supplied to come
res=ai.WinWait(File Download - Security Warning,,30)
puts res  #Used for debugging purpose

#Always try to Activate the pop-up window before using ControlClick fn()
res=ai.WinActivate(File Download - Security Warning)
puts res  #Used for debugging purpose

#Click on the specified control on the pop-up window
res=ai.ControlClick(File Download - Security Warning,,Save)
puts res  #Used for debugging purpose


puts\n #Place the cursor on the next line
#Wait for the pop-up window with the specified title supplied to come
res=ai.WinWait(Save As,,30)
puts res  #Used for debugging purpose

#Always try to Activate the pop-up window before using ControlClick fn()
res=ai.WinActivate(Save As)
puts res  #Used for debugging purpose

#Send the path in the pop-up window where you want to store the respective
file
res=ai.ControlSend(Save As,,Edit1, C:\AutoItV3.exe)
puts res  #Used for debugging purpose

#Click on the specified control on the pop-up window
res=ai.ControlClick(Save As,,Save)
puts res  #Used for debugging purpose

#Close the IE Browser window
ie.close

Thanks  Regards,
Ankur Gera
TCS

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Watir General group.
To post to this group, send email to watir-general@googlegroups.com
Before posting, please read the following guidelines: 
http://wiki.openqa.org/display/WTR/Support
To unsubscribe from this group, send email to 
watir-general-unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/watir-general
-~--~~~~--~~--~--~---



[wtr-general] Re: Has anyone tried using AutoIt to handle unexpected Popup windows

2009-10-21 Thread Pallavi Sharma
Ankur
I already know the code to handle a popup window via autoit if you know the
window tile.

Do you have an idea about handling a popup where i dont know what is the
windowtitle?

Means handling unexpected popup window, which will like handle pop up
whatever may be the window title.

If you have that then please share else, this all code is available with
watir wiki itself.


Pallavi.

On Wed, Oct 21, 2009 at 2:59 PM, Ankur Gera ankurg...@gmail.com wrote:


 Hi Pallavi,

 Below is the respective code :-

 require 'watir'
 require 'win32ole'

 #Supply AutoItX3 as an argument to the constructor of WIN32OLE
 #for handling pop-up windows using WIN32OLE objects.WIN32OLE will act as an
 interface
 #for handling pop-up windows using AutoItX3 functions.
 ai = WIN32OLE.new(AutoItX3.Control)

 #New IE Browser window
 ie=Watir::IE.new

 #Go to AutoIt website
 ie.goto(http://www.autoitscript.com/autoit3/downloads.shtml;)

 #Click Download AutoIt image
 ie.image(:src,/download_autoit/).click_no_wait


 #Wait for the pop-up window with the specified title supplied to come
 res=ai.WinWait(File Download - Security Warning,,30)
 puts res  #Used for debugging purpose

 #Always try to Activate the pop-up window before using ControlClick fn()
 res=ai.WinActivate(File Download - Security Warning)
 puts res  #Used for debugging purpose

 #Click on the specified control on the pop-up window
 res=ai.ControlClick(File Download - Security Warning,,Save)
 puts res  #Used for debugging purpose


 puts\n #Place the cursor on the next line
 #Wait for the pop-up window with the specified title supplied to come
 res=ai.WinWait(Save As,,30)
 puts res  #Used for debugging purpose

 #Always try to Activate the pop-up window before using ControlClick fn()
 res=ai.WinActivate(Save As)
 puts res  #Used for debugging purpose

 #Send the path in the pop-up window where you want to store the respective
 file
 res=ai.ControlSend(Save As,,Edit1, C:\AutoItV3.exe)
 puts res  #Used for debugging purpose

 #Click on the specified control on the pop-up window
 res=ai.ControlClick(Save As,,Save)
 puts res  #Used for debugging purpose

 #Close the IE Browser window
 ie.close

 Thanks  Regards,
 Ankur Gera
 TCS

 


--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Watir General group.
To post to this group, send email to watir-general@googlegroups.com
Before posting, please read the following guidelines: 
http://wiki.openqa.org/display/WTR/Support
To unsubscribe from this group, send email to 
watir-general-unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/watir-general
-~--~~~~--~~--~--~---



[wtr-general] Re: Has anyone tried using AutoIt to handle unexpected Popup windows

2009-10-21 Thread Ankur Gera
Hi Pallavi,

Use the AutoIt software(AutoIt Window Info) ,  you will get the info about
class of that pop-up window.What i have seen is that , this class remains
constant for almost all of the pop-up's , try to use this as an argument in
place of title.

Thanks  Regards,
Ankur Gera
TCS




--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Watir General group.
To post to this group, send email to watir-general@googlegroups.com
Before posting, please read the following guidelines: 
http://wiki.openqa.org/display/WTR/Support
To unsubscribe from this group, send email to 
watir-general-unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/watir-general
-~--~~~~--~~--~--~---



[wtr-general] Re: Has anyone tried using AutoIt to handle unexpected Popup windows

2009-10-21 Thread Pallavi Sharma
Yeah you are right about it, I know this, but was looking for something to
do with the using of regular expression in title. Would have helped my
implementation.
Anyways thanks, will try what you have suggested.

Thanks
Pallavi.



On Wed, Oct 21, 2009 at 3:36 PM, Ankur Gera ankurg...@gmail.com wrote:



 Hi Pallavi,

 Use the AutoIt software(AutoIt Window Info) ,  you will get the info about
 class of that pop-up window.What i have seen is that , this class remains
 constant for almost all of the pop-up's , try to use this as an argument in
 place of title.

 Thanks  Regards,
 Ankur Gera
 TCS




 


--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Watir General group.
To post to this group, send email to watir-general@googlegroups.com
Before posting, please read the following guidelines: 
http://wiki.openqa.org/display/WTR/Support
To unsubscribe from this group, send email to 
watir-general-unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/watir-general
-~--~~~~--~~--~--~---



[wtr-general] Re: Has anyone tried using AutoIt to handle unexpected Popup windows

2009-10-21 Thread Ankur Gera
Hi Pallavi,

Welcome.

Thanks  Regards,
Ankur Gera
TCS

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Watir General group.
To post to this group, send email to watir-general@googlegroups.com
Before posting, please read the following guidelines: 
http://wiki.openqa.org/display/WTR/Support
To unsubscribe from this group, send email to 
watir-general-unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/watir-general
-~--~~~~--~~--~--~---



[wtr-general] Re: Has anyone tried using AutoIt to handle unexpected Popup windows

2009-10-21 Thread al3kc


Do you create separate thread for check_for_popup method?
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Watir General group.
To post to this group, send email to watir-general@googlegroups.com
Before posting, please read the following guidelines: 
http://wiki.openqa.org/display/WTR/Support
To unsubscribe from this group, send email to 
watir-general-unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/watir-general
-~--~~~~--~~--~--~---



[wtr-general] Re: Has anyone tried using AutoIt to handle unexpected Popup windows

2009-10-21 Thread Pallavi Sharma
Yes, i don't do it using ruby, i do it using vb.net a framework which i have
build for automation solution using watir.


On Wed, Oct 21, 2009 at 5:15 PM, al3kc aleks.kiev...@gmail.com wrote:



 Do you create separate thread for check_for_popup method?
 


--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Watir General group.
To post to this group, send email to watir-general@googlegroups.com
Before posting, please read the following guidelines: 
http://wiki.openqa.org/display/WTR/Support
To unsubscribe from this group, send email to 
watir-general-unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/watir-general
-~--~~~~--~~--~--~---