It is because the focus is currently set on the browser and not on the
popup/window.  You need to first set focus on the popup or activate it:
autoit.WinActive(<name of the window>).


On Wed, May 13, 2009 at 3:43 PM, satish <spanchumar...@gmail.com> wrote:

>
>
> Can some one tell me why my code here does not work?
> It seems to be doing the Send action in the browser URL address area
> instead of in the text_field area.
>
> Here is my code..
> =================
> require "watir"
> require "win32ole"
> ie.text_field(:id,
>
> "ctl00_contentChildWindow_secUserDetails_subsecUserInfo_txtPhoneNumber_txtMaskTextBox_I").focus
> puts autoit = WIN32OLE.new('AutoItX3.Control')
> autoit = WIN32OLE.new('AutoItX3.Control')
> autoit.Send("{LEFT}")
> autoit.Send("{LEFT}")
> autoit.Send("{LEFT}")
> autoit.Send("{LEFT}")
> autoit.Send("{LEFT}")
>
> Can you some please let me know whats wrong with this code.
>
> Appreciate your help
>
> Thank you,
> Satish.
>
> >
>

--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---

Reply via email to