Drew Posted July 24, 2008 Share Posted July 24, 2008 I'm getting aggravated. I'm in the process of upgrading my current script to allow the feature of running minimized. Well , the button I'm needing to click... ( This is a IE automation script )... Well the button doesn't have a "ID" , and I'm not sure that you can use what Ive been using to do this. Here's my script , and my functions script. Note: The main point of this is the _Banking() function. Main Script: #include <IE.au3> #include <Mobsters.au3> Global $oIE If WinExists( "MySpace -") Then $oIE = _IEAttach("MySpace") ;~ WinActivate( "MySpace -") WinSetState("", "", @SW_MAXIMIZE) Else $oIE = _IECreate ("www.myspace.com", 1) WinSetState("", "", @SW_MAXIMIZE) EndIf _Banking() Functions: expandcollapse popup;Random Info ;=================== ;Banking Tab: 271, 245 ;Main Tab: 390, 206 ;Missions Tab: 159, 244 ;Territory Tab: 231, 246 ;Fight Tab: 413, 244 ;Refresh tab: 807, 207 ;Deposit Button: 579, 377 ;=================== Func _Opener() If WinExists( "MySpace -") Then $oIE = _IEAttach("MySpace") ;~ WinActivate( "MySpace -") WinSetState("", "", @SW_MAXIMIZE) Else $oIE = _IECreate ("www.myspace.com", 1) WinSetState("", "", @SW_MAXIMIZE) EndIf EndFunc Func _Banking() ;~ WinActivate( "MySpace - Windows Internet Explorer") MouseClick( "left", 271, 245, 1, 0) $sMyString = "REFRESH" $oLinks = _IELinkGetCollection($oIE) For $oLink In $oLinks $sLinkText = _IEPropertyGet($oLink, "innerText") If StringInStr($sLinkText, $sMyString) Then _IEAction($oLink, "click") ExitLoop EndIf Next _IELoadWait($oIE) ;~ MouseClick( "left", 807, 207, 1, 0) _IELoadWait($oIE) Sleep( 1000 ) $DepositClick = PixelSearch( 515, 348, 632, 413, 0x39599C) If @Error = 1 Then Sleep( 1000 ) Else MouseClick( "left", 579, 377, 1, 0) EndIf EndFunc Func _ClickMobsters() $sMyString = "Mobsters" $oLinks = _IELinkGetCollection($oIE) For $oLink In $oLinks $sLinkText = _IEPropertyGet($oLink, "innerText") If StringInStr($sLinkText, $sMyString) Then _IEAction($oLink, "click") ExitLoop EndIf Next _IELoadWait($oIE) EndFunc ;==>_ClickMobsters Func _AutoLogin() ;Attempt to auto-login $EmailBox = PixelSearch(767, 521, 826, 569, 0xFFFFFF) MouseClick("left", $EmailBox[0], $EmailBox[1], 2) $Email = IniRead(@ScriptDir & "\Config.ini", "Config", "Email", "Default") $Password = IniRead(@ScriptDir & "\Config.ini", "Config", "Password", "Default") Send($Email) Send("{TAB}") Sleep(100) Send($Password) Sleep(100) Send("{ENTER}") _IELoadWait($oIE) EndFunc ;==>_AutoLogin Link to comment Share on other sites More sharing options...
Drew Posted July 24, 2008 Author Share Posted July 24, 2008 (edited) Can no one help me? Edited July 24, 2008 by Drew Link to comment Share on other sites More sharing options...
enaiman Posted July 25, 2008 Share Posted July 25, 2008 wowPosted Today, 08:47 AMPosted Today, 08:59 AM... 12 minutes and nobody gave him an answer?? Be patient ... if possible, some1 will help you SNMP_UDF ... for SNMPv1 and v2c so far, GetBulk and a new example script wannabe "Unbeatable" Tic-Tac-Toe Paper-Scissor-Rock ... try to beat it anyway :) Link to comment Share on other sites More sharing options...
weaponx Posted July 25, 2008 Share Posted July 25, 2008 If the button you are clicking is in fact html then this shouldn't be a problem. If its a Java applet or Flash it will be more difficult. 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