Quantcast
Channel: AutoIt v3 - General Help and Support
Viewing all articles
Browse latest Browse all 12506

_IEFormElementSetValue in INPUT - $o_object.fireEvent("OnClick")^ ERROR

$
0
0

I use IE in for next loop

to set value in INPUT and search something on the web

when site take me back response then I read what I need and back to home site

and again set value ....

 

 

 

<INPUT style="WIDTH: 135px" id=MainContent_txtAdvPesel maxLength=11 type=text name=ctl00$MainContent$txtAdvPesel>

 

$oIE_aspnetForm = _IEGetObjById($oIE, "aspnetForm") $oIE_aspnetForm_ctl00_MainContent_txtAdvPesel = _IEFormElementGetObjByName($oIE_aspnetForm, "ctl00$MainContent$txtAdvPesel")   ;When I use Consolewrite(isobj($oIE_aspnetForm_ctl00_MainContent_txtAdvPesel) & @CRLF) ;then result is always = 1     ;I Check to be sure that I have taken correct OBJ Consolewrite($oIE_aspnetForm_ctl00_MainContent_txtAdvPesel.name & @CRLF) ;then result is always = ctl00$MainContent$txtAdvPesel       ;so why not always but very often ;this function _IEFormElementSetValue($oIE_aspnetForm_ctl00_MainContent_txtAdvPesel, $s_new_value, 1) ; return to me that error

 

 

;~ C:\Program Files\AutoIt3\Include\ie.au3 (1307) : ==> The requested action with this object has failed.:

 

;~ $o_object.fireEvent("OnClick")
;~ $o_object.fireEvent("OnClick")^ ERROR
 

 

 

 

I do severals test by adding

 

sleep - do not take any diffrence 

trying to _IEAction($oIE_aspnetForm_ctl00_MainContent_txtAdvPesel,"click") - before SetValue

trying to _IEAction($oIE_aspnetForm_ctl00_MainContent_txtAdvPesel,"focus") - before SetValue

 
 
Click And Focus give me back that same errors
 
When I start again "For ... to ..." then its can do for example 50 more steps and crash 
sometimes do only 10 step somtimes 30 steps a 
 
 

Viewing all articles
Browse latest Browse all 12506

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>