anilmanyam 0 Posted March 28, 2011 I am a newbie and trying to do a simple task to automate navigation through a website When i open the url with the _IEcreate function a new window opens and i am able to click any link on it Once the control navigates to the next page i am not able to click on any link Here's my script #include <IE.au3> $URL= "http://www.rediff.com" $IE = _IECreate ("http://www.rediff.com") WinActivate("[CLASS:IEFrame]","") WinSetState("[CLASS:IEFrame]", "", @SW_MAXIMIZE) _IELoadWait($IE) $string1 = "News" _IELinkClickByText($IE,$string1) ;Control navigates to the next page now string2 = "More New Stories" _IELinkClickByText($IE,$st2) ; Not working ;I guess $IE still points to "http://www.rediff.com" ;What do i need to do to make $IE point to the current page now so that i can click a link on it Share this post Link to post Share on other sites
Melba23 3,455 Posted March 28, 2011 anilmanyam,I am a newbieObviously so as you have posted your question in a section clearly marked as "Example scripts - This is not a general support forum!". But welcome to the AutoIt forum anyway - I have asked for your thread to be moved to the correct section. M23 Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind Open spoiler to see my UDFs: Spoiler ArrayMultiColSort ---- Sort arrays on multiple columnsChooseFileFolder ---- Single and multiple selections from specified path treeview listingDate_Time_Convert -- Easily convert date/time formats, including the language usedExtMsgBox --------- A highly customisable replacement for MsgBoxGUIExtender -------- Extend and retract multiple sections within a GUIGUIFrame ---------- Subdivide GUIs into many adjustable framesGUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView itemsGUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeViewMarquee ----------- Scrolling tickertape GUIsNoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxesNotify ------------- Small notifications on the edge of the displayScrollbars ----------Automatically sized scrollbars with a single commandStringSize ---------- Automatically size controls to fit textToast -------------- Small GUIs which pop out of the notification area Share this post Link to post Share on other sites
JohnOne 1,603 Posted March 28, 2011 Probably because there is no $st2 variable. AutoIt Absolute Beginners Require a serial Pause Script Video Tutorials by Morthawt ipify Monkey's are, like, natures humans. Share this post Link to post Share on other sites
anilmanyam 0 Posted March 28, 2011 Probably because there is no $st2 variable.that was a typing mistake while posting.... it is _IELinkClickByText($IE,$string2)So wats wrong....I am not getting any error... and the last couple of lines execute but to no effect Share this post Link to post Share on other sites
DaleHohm 65 Posted March 28, 2011 Are you running this in SciTe with F5? If not, do so and look at thte messages in the console at the bottom. You say you rea not getting an error, but you are not checking the return status of _IELinkClickByText, so you would not know unless you can see the console. Dale Free Internet Tools: DebugBar, AutoIt IE Builder, HTTP UDF, MODIV2, IE Developer Toolbar, IEDocMon, Fiddler, HTML Validator, WGet, curlMSDN docs: InternetExplorer Object, Document Object, Overviews and Tutorials, DHTML Objects, DHTML Events, WinHttpRequest, XmlHttpRequest, Cross-Frame Scripting, Office object modelAutomate input type=file (Related)Alternative to _IECreateEmbedded? better: _IECreatePseudoEmbedded Better Better?IE.au3 issues with Vista - WorkaroundsSciTe 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 Share this post Link to post Share on other sites
anilmanyam 0 Posted March 28, 2011 Are you running this in SciTe with F5? If not, do so and look at thte messages in the console at the bottom. You say you rea not getting an error, but you are not checking the return status of _IELinkClickByText, so you would not know unless you can see the console.DaleDale there's a warning which says "Warning from function _IELinkClickByText, $_IEStatus_NoMatch"I am having a hard time understanding what's wrong with the script and why i am not able to click on any link after i navigate successfully to the next page..I would appreciate your help very much.Thanks in advanceAnil Share this post Link to post Share on other sites