Gnomercy Posted June 29, 2005 Share Posted June 29, 2005 I am trying to automate stuff in Rhapsody but like most music apps, iTunes, WindowsMediaPlayer they've got the Music Stores. AutoIt doesn't like these too well. WinSpy shows these as Internet Explorer_Server class. I've tried digging through the forums and have played around with beta and the com objects. But everything I've read so far have been about stand alone Internet Explorer. I am a noob to com and have been toying w/AutoIt for a few days now. Can a pro point me to some example code or give some search phrase to continue my search. How do you automate a web page that is inside an application? Thanks, Gnomy Link to comment Share on other sites More sharing options...
Valuater Posted June 29, 2005 Share Posted June 29, 2005 You could try this... to make an automation programhttp://www.autoitscript.com/forum/index.php?showtopic=13024#***** or.. to make your ownUse AU3info ( This maybe the WinSpy you referred to)*** then use (from Help)ControlCommand --------------------------------------------------------------------------------Sends a command to a control.ControlCommand ( "title", "text", controlID, "command", "option" )*** or one of the related controls on this help pagegood luck8) Link to comment Share on other sites More sharing options...
Gnomercy Posted June 29, 2005 Author Share Posted June 29, 2005 You could try this... to make an automation programhttp://www.autoitscript.com/forum/index.php?showtopic=13024#***** or.. to make your ownUse AU3info ( This maybe the WinSpy you referred to)*** then use (from Help)ControlCommand --------------------------------------------------------------------------------Sends a command to a control.ControlCommand ( "title", "text", controlID, "command", "option" )*** or one of the related controls on this help pagegood luck8)<{POST_SNAPBACK}>The problem with ControlCommand is that it requires a ControlID.The AutoIt Active WindowInfo reports no ID but offers a class name.Is there another control where I can pass the classname or Handlefor situations like this?Press CTRL-ALT-F to pause the display.>>>>>>>>>>>> Window Details <<<<<<<<<<<<<Title: RhapsodyClass: TEST_WIN32WNDSize: X: 18 Y: 58 W: 987 H: 766>>>>>>>>>>> Mouse Details <<<<<<<<<<<Screen: X: 546 Y: 479Cursor ID: 0>>>>>>>>>>> Pixel Color Under Mouse <<<<<<<<<<<RGB: Hex: 0xDEE7F0 Dec: 14608368>>>>>>>>>>> Control Under Mouse <<<<<<<<<<<Size: X: 434 Y: 256 W: 539 H: 463Control ID: ClassNameNN: MFCReportCtrl5Text: searchresults.externalStyle: 0x5210282AExStyle: 0x00000000(Control is hidden)>>>>>>>>>>> Status Bar Text <<<<<<<<<<< Link to comment Share on other sites More sharing options...
Valuater Posted June 29, 2005 Share Posted June 29, 2005 I think this is it AutoItSetOption("WinTitleMatchMode", 4) ControlCommand ( "title", "text", ClassName= MFCReportCtrl5, "command", "option" ) "ClassName=MFCReportCtrl5" **** no spaces read help 8) Link to comment Share on other sites More sharing options...
Gnomercy Posted June 30, 2005 Author Share Posted June 30, 2005 I've been trying a number of stuff Namely AutoItSetOption("WinTitleMatchMode", 4) WinActivate ( "Rhapsody") ;$var = ControlFocus("Rhapsody", "", "ClassNameNN=TEST_WIN32WND55") ;$var=ControlCommand("Rhapsody", "", "ClassName=TEST_WIN32WND55", "IsEnabled", "") ;$var = ControlFocus("Rhapsody", "", "ClassNameNN=TEST_WIN32WND85") ;$var = ControlClick("ClassNameNN=TEST_WIN32WND85") ;$var = ControlClick('ClassNameNN=TEST_WIN32WND85', "") $var = ControlClick("Rhapsody", "", "ClassNameNN=TEST_WIN32WND85") MsgBox(0, "Control Focus", $var) ;Returns 0 :( ;ControlCommand("Rhapsody", "", "ClassName=TEST_WIN32WND55", "EditPaste", 'Sum 41') The problem is that I am unable to click on controls based on the ClassNameNN. Am I doing this right? I tried looking in the help and forums. The help only infers that ClassNameNN can be used to identify a window. But there's nothing for it in controls. I want to be able to ControlFocus, ControlClick, Send and all the normal stuff. But using the ClassName as an ID isn't working for me BTW Thanks for your help it's much appreciated. Link to comment Share on other sites More sharing options...
Valuater Posted June 30, 2005 Share Posted June 30, 2005 heres an example that clicks... (not mine)sorry i dont know who the author isRun('control inetcpl.cpl')WinWait('Internet Properties')ControlClick('Internet Properties', '', 'Button6')WinWait('Delete Cookies')ControlClick('Delete Cookies', '', 'Button1')If Not WinWaitActive('Internet Properties') Then WinActivate('Internet Properties')ControlClick('Internet Properties', '', 'Button7')WinWait('Delete Files')ControlClick('Delete Files', '', 'Button2')If Not WinWaitActive('Internet Properties') Then WinActivate('Internet Properties')ControlClick('Internet Properties', '', 'Button10')WinWait('Internet Options')ControlClick('Internet Options', '', 'Button1')WinWait('Internet Properties')ControlClick('Internet Properties', '', 'Button15')hope it helps8) Link to comment Share on other sites More sharing options...
Valuater Posted June 30, 2005 Share Posted June 30, 2005 This should help alsohttp://www.autoitscript.com/forum/index.ph...241&hl=AdAware#8) 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