Hello, I'm not sure if this is part of AutoIt, but have you tried send_keys?
@browser.send_keys('{ENTER}') On Oct 7, 1:52 am, Ozzi <usmanhhuss...@gmail.com> wrote: > Hi Guys, > > I have a problem... > > I need to hit the ENTER button on the keyboard on my tests. I was > using AutoIT when I was working on Windows and had this: > require 'rubygems' > require 'win32ole' > require 'watir-webdriver' > > autoit = WIN32OLE.new('AutoITX3.Control') > autoit.WinActivate('OK') > autoit.Send('{ENTER}') > > BUT now im using a MAC and this does not work. Ive tried to use rb- > appscript after searching the net and have come up with this: > require 'rubygems' > require 'appscript' > require 'watir-webdriver' > > te = app('OK') > te.activate > te.key.ENTER > > BUT this is not working... Has anyone else used rb-appscript? > any help would be great. i need this fixed by the end of play today as > all of my scripts are failing. would really appreciate anyone who can > tell me how to hit the ENTER keystroke on a MAC... > > Kind regards, > Usman Hussain -- Before posting, please read http://watir.com/support. In short: search before you ask, be nice. watir-general@googlegroups.com http://groups.google.com/group/watir-general watir-general+unsubscr...@googlegroups.com