scatterjoy Posted February 18, 2009 Share Posted February 18, 2009 Hi, Newbie here thinks there has to be a better way. I want to run slacker radio as an alarm clock. Alarm functions tbd later (help welcome). This works, but if slacker's window name changes, I could sleep through my day job. What's the right way to do this? (If slacker radio has this feature, I can't find it, but I'd rather learn how to use AutoIT anyway) Run(@ProgramFilesDir & "\Internet Explorer\IEXPLORE.EXE") WinWaitActive("Google - Windows Internet Explorer") WinSetState("Google - Windows Internet Explorer","",@SW_MAXIMIZE) MouseClick("",225,40) send("http://www.slacker.com/") send("{ENTER}") WinSetState("Slacker Personal Radio - Listen to Free Internet Radio Stations - Windows Internet Explorer","",@SW_MAXIMIZE) Sleep(20000) MouseClick("",481,386) Sleep(2000) MouseClick("",818,386) ThanksSlacker_Run_v1.au3 Link to comment Share on other sites More sharing options...
jebus495 Posted February 18, 2009 Share Posted February 18, 2009 Hi, Newbie here thinks there has to be a better way. I want to run slacker radio as an alarm clock. Alarm functions tbd later (help welcome).This works, but if slacker's window name changes, I could sleep through my day job.What's the right way to do this? (If slacker radio has this feature, I can't find it, but I'd rather learn how to use AutoIT anyway)Run(@ProgramFilesDir & "\Internet Explorer\IEXPLORE.EXE")WinWaitActive("Google - Windows Internet Explorer")WinSetState("Google - Windows Internet Explorer","",@SW_MAXIMIZE)MouseClick("",225,40)send("http://www.slacker.com/")send("{ENTER}")WinSetState("Slacker Personal Radio - Listen to Free Internet Radio Stations - Windows Internet Explorer","",@SW_MAXIMIZE)Sleep(20000)MouseClick("",481,386)Sleep(2000)MouseClick("",818,386)Thanks_IENavigate() ? Link to comment Share on other sites More sharing options...
exodius Posted February 18, 2009 Share Posted February 18, 2009 _IENavigate() ?jebus495 is totally on the mark, dig into those _IE functions and you're going to feel silly for how easy you should be able to do this. Link to comment Share on other sites More sharing options...
scatterjoy Posted February 18, 2009 Author Share Posted February 18, 2009 That's the way to do it. For anyone interested: #include <IE.au3> $oIE = _IECreate ("http://www.slacker.com/",0,1,1,1) WinSetState("Slacker Personal Radio - Listen to Free Internet Radio Stations - Windows Internet Explorer","",@SW_MAXIMIZE) ;pause while radio loads and then choose station. Open C:\Program Files\AutoIt3\au3info to use mouse finder and change station Sleep(20000) MouseClick("",481,386) Sleep(2000) MouseClick("",818,386) Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now