ReleasemyHand Posted September 25, 2008 Posted September 25, 2008 I would like to open the link in the page which contains the HTML below, but I have no idea how to get it done, below all the links were programed in onclick="java script:location.href=" <TABLE cellSpacing=1 cellPadding=2 width="400px" border=0 bgColor=#000000> <tr> <td class="th" width="100%">Process steps listed</td> <td class="th"> Number </td> </tr> <tr class=tr1> <tr class=tr1> <td onmouseover="java script:this.className='ontaskmouseover';" onmouseout="java script:this.className = parentElement.className" onclick="java script:location.href='/tasks/tasks-list.asp?fName=selTaskID&fVal=900038&tskID=900038&tskName=Coordination+Team&dummy=24122,2560405731'">¤ Coordination Team</td> <td class=tasknumber>775</td> </tr> <tr class=tr0> <td onmouseover="java script:this.className='ontaskmouseover';" onmouseout="java script:this.className = parentElement.className" onclick="java script:location.href='/tasks/tasks-list.asp?fName=selTaskID&fVal=100028&tskID=100028&tskName=Shipment+on+Hold&dummy=15836,2984657288'">¤ Shipment on Hold</td> <td class=tasknumber>34</td> </tr> <tr class=tr1> <td onmouseover="java script:this.className='ontaskmouseover';" onmouseout="java script:this.className = parentElement.className" onclick="java script:location.href='/tasks/tasks-list.asp?fName=selTaskID&fVal=900036&tskID=900036&tskName=Process+Amendment&dummy=93810,0159168243'">¤ Process Amendment</td> <td class=tasknumber>14</td> </tr> <tr class=tr0> <td onmouseover="java script:this.className='ontaskmouseover';" onmouseout="java script:this.className = parentElement.className" onclick="java script:location.href='/tasks/tasks-list.asp?fName=selTaskID&fVal=900039&tskID=900039&tskName=Process+Shipment&dummy=33330,9412002563'">¤ Process Shipment</td> <td class=tasknumber>4</td> </tr> <tr class=tr1> <!-- Start RQ-0249 --> <!--<td onmouseover="java script:this.className='ontaskmouseover';" onmouseout="java script:this.className = parentElement.className" onclick="java script:location.href='/tasks/clarify-list.asp'">¤ Shipments set for Clarification</td>--> <td onmouseover="java script:this.className='ontaskmouseover';" onmouseout="java script:this.className = parentElement.className" onclick="java script:location.href='/tasks/clarify-list.asp?dummy=14768,1653499603'">¤ Shipments set for Clarification</td> <!-- End RQ-0249 --> <td class=tasknumber>12</td> </tr> </table>
Community On Patrol Posted September 25, 2008 Posted September 25, 2008 Hi ReleasemyHand, Please create descriptive topics. Using one word topics makes it really difficult to use the search feature, and those that could probably answer your question will probably not even read your thread. Doing it enough could cause your posting privileges to be taken away all together, and we don't want that . Thanks.
NeoFoX Posted September 25, 2008 Posted September 25, 2008 Hey ReleasemyHand, I had the same problem with those damn Javascript enabled buttons I figured out my 'clicks' worked with this nice function: _IELinkClickByIndex(); Try to play with the index number, and if it's going correctly you'll see some magic clicks on those javascript buttons! Greetz, Neo [center][font="Arial"]--- The Neo and Only --- [/font][font="Arial"]--Projects---[/font]Image to Text converterText to ASCII converter[/center]
DaleHohm Posted September 25, 2008 Posted September 25, 2008 The previous suggestion would work except the element in the posted HTML is not a link, but rather a table cell with an onclick event. There are a couple of ways to deal with this in IE.au3. The location.href in the onclick event simply sets the browser URL, so you can use _IENavigate to that URL. To do exactly what you ask, you can either loop through the table cells and click the one you want... $oTDs = _IETagnameGetCollection($oIE, "td") For $oTD in $oTDs If String(_IEPropertyGet($oTD, "innerHTML", "¤ Shipments set for Clarification") Then _IEAction($oTD, "click") Next 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
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