narayanjr Posted June 25, 2007 Share Posted June 25, 2007 $oIE = _IECreate ("https://ssl.rapidshare.com/cgi-bin/collectorszone.cgi") $oForm = _IEFormGetCollection ($oIE, 0) $oQuery = _IEFormElementGetCollection ($oForm, 0) $oForm2 = _IEFormGetCollection ($oIE, 0) $oQuery2 = _IEFormElementGetCollection ($oForm2, 1) _IEFormElementSetValue($oQuery, "acct") _IEFormElementSetValue($oQuery2, "pass") _IEFormSubmit($oForm) all of that works so far it opens up the page and enters acct and password and hits the login button but then the page changes and i need to send text to one more form then hit 1 more button but how do i change $oIE without using _IECreate? This is the first time using _IE functions so if im just asking a really stupid questions point me to the right file in the help file. Thanks Link to comment Share on other sites More sharing options...
DaleHohm Posted June 25, 2007 Share Posted June 25, 2007 Suggest you simply add an _IELoadWait($oIE) to the end of your script to insure that the document load is complete and then continue on using $oIE $oIE in actuality points to the browser shell that contains the document and the _IE functions automatically drill down to the embedded document as necessary, so even when the document and url change you are still all set. It's one of the design features of IE.au3 that saves you lots and lots of code. Dale Free Internet Tools: DebugBar, AutoIt IE Builder, HTTP UDF, MODIV2, IE Developer Toolbar, IEDocMon, Fiddler, HTML Validator, WGet, curl MSDN docs: InternetExplorer Object, Document Object, Overviews and Tutorials, DHTML Objects, DHTML Events, WinHttpRequest, XmlHttpRequest, Cross-Frame Scripting, Office object model Automate input type=file (Related) Alternative to _IECreateEmbedded? better: _IECreatePseudoEmbedded Better Better? IE.au3 issues with Vista - Workarounds SciTe Debug mode - it's magic: #AutoIt3Wrapper_run_debug_mode=Y Doesn't work needs to be ripped out of the troubleshooting lexicon. It means that what you tried did not produce the results you expected. It begs the questions 1) what did you try?, 2) what did you expect? and 3) what happened instead? Reproducer: a small (the smallest?) piece of stand-alone code that demonstrates your trouble Link to comment Share on other sites More sharing options...
narayanjr Posted June 25, 2007 Author Share Posted June 25, 2007 Thank You, I understand that part now, but I am still having problems with this thing.#include <IE.au3> $oIE = _IECreate("https://ssl.rapidshare.com/cgi-bin/collectorszone.cgi") $oForm = _IEFormGetCollection ($oIE, 0) $oQuery = _IEFormElementGetCollection ($oForm, 0) $oForm2 = _IEFormGetCollection ($oIE, 0) $oQuery2 = _IEFormElementGetCollection ($oForm2, 1) _IEFormElementSetValue($oQuery, "acct") _IEFormElementSetValue($oQuery2, "pass") _IEFormSubmit($oForm) _IELoadWait($oIE) $oForm3 = _IEFormGetCollection ($oIE, 0) $oQuery3 = _IEFormElementGetCollection ($oForm3, 0) _IEFormElementSetValue($oQuery3, "File.Filet") _IEFormSubmit($oForm3) _IELoadWait($oIE)I need it to send text to the Red boxed place then click the Green boxed placeBut i cant seem to get any of the indexes right so it always either just writes the text to one of the buttons on the page or does nothing.I really need help with it, It is really starting to make me mad that I cant get this thing to work properly.Thanks Link to comment Share on other sites More sharing options...
DaleHohm Posted June 26, 2007 Share Posted June 26, 2007 Make sure you run your code in SciTe and then carefully look at the console output... it tries really hard to help you find your own issues. Dale Free Internet Tools: DebugBar, AutoIt IE Builder, HTTP UDF, MODIV2, IE Developer Toolbar, IEDocMon, Fiddler, HTML Validator, WGet, curl MSDN docs: InternetExplorer Object, Document Object, Overviews and Tutorials, DHTML Objects, DHTML Events, WinHttpRequest, XmlHttpRequest, Cross-Frame Scripting, Office object model Automate input type=file (Related) Alternative to _IECreateEmbedded? better: _IECreatePseudoEmbedded Better Better? IE.au3 issues with Vista - Workarounds SciTe Debug mode - it's magic: #AutoIt3Wrapper_run_debug_mode=Y Doesn't work needs to be ripped out of the troubleshooting lexicon. It means that what you tried did not produce the results you expected. It begs the questions 1) what did you try?, 2) what did you expect? and 3) what happened instead? Reproducer: a small (the smallest?) piece of stand-alone code that demonstrates your trouble Link to comment Share on other sites More sharing options...
narayanjr Posted June 26, 2007 Author Share Posted June 26, 2007 --> IE.au3 Error from function _IEFormElementSetValue, $_IEStatus_InvalidObjectType (Browser securuty prevents SetValue of TYPE=FILE)thats what it said as one of the lines, i guess that means its not possible? Link to comment Share on other sites More sharing options...
DaleHohm Posted June 26, 2007 Share Posted June 26, 2007 It's in the docs man... take a look at the remarks for _IEFormElementSetValue Dale Free Internet Tools: DebugBar, AutoIt IE Builder, HTTP UDF, MODIV2, IE Developer Toolbar, IEDocMon, Fiddler, HTML Validator, WGet, curl MSDN docs: InternetExplorer Object, Document Object, Overviews and Tutorials, DHTML Objects, DHTML Events, WinHttpRequest, XmlHttpRequest, Cross-Frame Scripting, Office object model Automate input type=file (Related) Alternative to _IECreateEmbedded? better: _IECreatePseudoEmbedded Better Better? IE.au3 issues with Vista - Workarounds SciTe Debug mode - it's magic: #AutoIt3Wrapper_run_debug_mode=Y Doesn't work needs to be ripped out of the troubleshooting lexicon. It means that what you tried did not produce the results you expected. It begs the questions 1) what did you try?, 2) what did you expect? and 3) what happened instead? Reproducer: a small (the smallest?) piece of stand-alone code that demonstrates your trouble 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