Jump to content

jacobp

Members
  • Posts

    3
  • Joined

  • Last visited

Everything posted by jacobp

  1. I appreciate your response, but neither of your methods would input any data into the box either. The form itself it a blank text box that gets populated from a browse button. I discovered though that if I type in the local path of the file that it bypasses the browse button. Unfortunately, I've failed being able to automate either of these functions so far. My way of grabbing the objects did seem screwed up but whenever I read them they had the correct values. When I did _IEAction($oQuery1,"click") it would work but the script would hang with the windows, Choose File diaglog box. I tried the _IEAction($oquery,"focus") but the controlsend would never send an {enter} down. I'm really at a lose for words and gave up awhile ago. Maybe it'll come to me on Monday.
  2. I've been playing around with this for awhile now and it has me stumped. I'm trying to automate a webform and have been unsuccessful in editing the form input. Send is the only method that I've got working but I can't use that as the script will run in the background. My attempts at using control send failed miserably. My attempts at _IEFormElementSetValue failed as well. Can anyone offer any suggestions, direction, guidance, or direction on how I can accomplish this? Here's the current AutoIT code I've been using. $new_page = "http://10.131.180.109/RemoteAdmin/updateform.html" $tmp_page = _IECreate($new_page,0,1,0,-1) ;_IELoadWait($tmp_page,100,2000) $Auth_Active=winwaitactive("Connect to","",20000) $results=WinExists("Connect to") if $Auth_Active = 1 Then controlsend("Connect to","","Edit2","admin") controlsend("Connect to","","Edit3","smartlane") controlclick("Connect to","","Button2") EndIf _IEloadwait($tmp_page,1000,15000) $oForms = _IEFormGetCollection ($tmp_page,0) $oForm = _IEFormGetObjByName ($oForms, $oForms.name) $oQuery1 = _IEFormElementGetCollection ($oForm, 0) _ieformelementsetvalue($oQuery1,"C:\Work\Irisys\SDI_files\SmartlaneCAB.CAB",1) I've also tried this: $new_page = "http://10.131.180.109/RemoteAdmin/updateform.html" $tmp_page = _IECreate($new_page,0,1,0,-1) ;_IELoadWait($tmp_page,100,2000) $Auth_Active=winwaitactive("Connect to","",20000) $results=WinExists("Connect to") if $Auth_Active = 1 Then controlsend("Connect to","","Edit2","admin") controlsend("Connect to","","Edit3","smartlane") controlclick("Connect to","","Button2") EndIf _IEloadwait($tmp_page,1000,15000) $oForms = _IEFormGetCollection ($tmp_page,0) $oForm = _IEFormGetObjByName ($oForms, $oForms.name) $oQuery1 = _IEFormElementGetCollection ($oForm, 0) $hwnd=_IEPropertyGet($oForm,"hwnd") controlsend($hwnd,"","","C:\Work\Irisys\SDI_files\SmartlaneCAB.CAB") I've tried a few other things that I can't remember off the top of my head as well but to no avail. Many of the other attempts were various ways of using controlsend. Here's the html from the page. <form name="configForm" enctype='multipart/form-data' action='/web/SLPlugin.dll?action=UpdateSystem' onsubmit="return initReporting();" method=post> Please select the SDI update CAB file to upload<br /> <br /> <input name=cabfile id=cabfile type=file size=40 onchange='checkCAB();' /><br /> <div id='cabError' style='color: #ff3333;'></div> <br /> <input type=hidden name=submitupdate value="Upgrade SDI" /> <div class="controls"><a href="#" class="button" onclick="initReporting();"><b><b><b>Update SDI</b></b></b></a></div> <br clear="both" /> </form>
  3. You can use a combination between @hour and @min. When it matches run a command, then sleep for 61000.
×
×
  • Create New...