Jump to content
Sign in to follow this  
Bert

Scripting a webpage trouble

Recommended Posts

Bert

I'm making a attempt to script Desktop Tower Defense. As usual, I'm having fits with the IE part. I know there is a help file, and I read it over and over. What drives me crazy is understanding what _ie command to interact with something on the page.

This is the code for the webpage I'm dealing with.

CODE
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">

<html>

<head>

<link rel="stylesheet" type="text/css" href="res://ieframe.dll/ErrorPageTemplate.css" />

<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />

<title>Navigation Canceled</title>

<script src="res://ieframe.dll/errorPageStrings.js" language="javascript" type="text/javascript">

</script>

<script src="res://ieframe.dll/httpErrorPagesScripts.js" language="javascript" type="text/javascript">

</script>

</head>

<body onload="java script:navCancelInit(); ">

<table width="730" cellpadding="0" cellspacing="0" border="0">

<!-- Error title -->

<tr>

<td id="infoIconAlign" width="60" align="left" valign="top" rowspan="2">

<img src="res://ieframe.dll/info_48.png" id="infoIcon" alt="Info icon">

</td>

<td id="mainTitleAlign" valign="middle" align="left" width="*">

<h1 id="mainTitle">Navigation to the webpage was canceled</h1>

</td>

</tr>

<tr>

<!-- This row is for HTTP status code, as well as the divider-->

<td id="errorCodeAlign" class="errorCodeAndDivider" align="right">&nbsp;

<div class="divider"></div>

</td>

</tr>

<!-- Error Body -->

<!-- What you can do -->

<tr>

<td>

&nbsp;

</td>

<td id="whatToTryAlign" valign="top" align="left">

<h2 id="whatToTry">What you can try:</h2>

</td>

</tr>

<!-- refresh page -->

<tr>

<td >

&nbsp;

</td>

<td id="refreshPageAlign" align="left" valign="middle">

<h4>

<table>

<tr>

<td valign="top">

<img src="res://ieframe.dll/bullet.png" border="0" alt="" class="actionIcon">

</td>

<td valign="top">

<span id="navCancelContainer"></span><noscript id="refreshPage">Refresh the page.</noscript>

</td>

</tr>

</table>

</h4>

</td>

</tr>

</table>

</body>

</html>

What would be really helpful is a tool that when you hover your mouse on a item in a webpage, some information would be presented in a window telling what to do to interact with the item. For now, can someone show me how to click on "Refresh the page." with a code example?

I tried various things, and everything comes back as a "0"

Share this post


Link to post
Share on other sites
martin

I'm making a attempt to script Desktop Tower Defense. As usual, I'm having fits with the IE part. I know there is a help file, and I read it over and over. What drives me crazy is understanding what _ie command to interact with something on the page.

This is the code for the webpage I'm dealing with.

CODE
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">

<html>

<head>

<link rel="stylesheet" type="text/css" href="res://ieframe.dll/ErrorPageTemplate.css" />

<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />

<title>Navigation Canceled</title>

&lt;script src="res://ieframe.dll/errorPageStrings.js" language="javascript" type="text/javascript">

</script>

&lt;script src="res://ieframe.dll/httpErrorPagesScripts.js" language="javascript" type="text/javascript">

</script>

</head>

<body onload="java script:navCancelInit(); ">

<table width="730" cellpadding="0" cellspacing="0" border="0">

<!-- Error title -->

<tr>

<td id="infoIconAlign" width="60" align="left" valign="top" rowspan="2">

<img src="res://ieframe.dll/info_48.png" id="infoIcon" alt="Info icon">

</td>

<td id="mainTitleAlign" valign="middle" align="left" width="*">

<h1 id="mainTitle">Navigation to the webpage was canceled</h1>

</td>

</tr>

<tr>

<!-- This row is for HTTP status code, as well as the divider-->

<td id="errorCodeAlign" class="errorCodeAndDivider" align="right">&nbsp;

<div class="divider"></div>

</td>

</tr>

<!-- Error Body -->

<!-- What you can do -->

<tr>

<td>

&nbsp;

</td>

<td id="whatToTryAlign" valign="top" align="left">

<h2 id="whatToTry">What you can try:</h2>

</td>

</tr>

<!-- refresh page -->

<tr>

<td >

&nbsp;

</td>

<td id="refreshPageAlign" align="left" valign="middle">

<h4>

<table>

<tr>

<td valign="top">

<img src="res://ieframe.dll/bullet.png" border="0" alt="" class="actionIcon">

</td>

<td valign="top">

<span id="navCancelContainer"></span><noscript id="refreshPage">Refresh the page.</noscript>

</td>

</tr>

</table>

</h4>

</td>

</tr>

</table>

</body>

</html>

What would be really helpful is a tool that when you hover your mouse on a item in a webpage, some information would be presented in a window telling what to do to interact with the item. For now, can someone show me how to click on "Refresh the page." with a code example?

I tried various things, and everything comes back as a "0"

I can't help you much with this one, but I wondered if you've tried Send("{F5}")?


Serial port communications UDF Includes functions for binary transmission and reception.printing UDF Useful for graphs, forms, labels, reports etc.Add User Call Tips to SciTE for functions in UDFs not included with AutoIt and for your own scripts.Functions with parameters in OnEvent mode and for Hot Keys One function replaces GuiSetOnEvent, GuiCtrlSetOnEvent and HotKeySet.UDF IsConnected2 for notification of status of connected state of many urls or IPs, without slowing the script.

Share this post


Link to post
Share on other sites
DaleHohm

Are you certain that source is what you are wanting to work with?

The "Refresh this page" html will not do anything if you click on it.

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

Share this post


Link to post
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×