473,657 Members | 2,439 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

How automate Internet Explorer clicking links and entering data?

I need to be able to open up a URL and enter some data, press a button
and then wait for the page to load and then click a check box and
press another button.

Is there a good example on the internet on how to do this with vb.net?

Thanks for any help
Nov 20 '05 #1
12 23147
Hi MeNo,

I presume that you have a particular URL in mind.

In that case, take a look at the Html. You'll see where the Forms are and
where your inputs are. The inputs will have a name or an id. The form will
have a submit action - either Post or Get.

The task is to enter the data into the textboxes and click the checkboxes
and buttons, etc, right ?
Well, not quite. Try again.

The task is to get the right values into those inputs and get the Form to
submit?
Still not quite right. Try again.

The task is to call the URL in the way that it <would> be called if the
data <had> been entered and the boxes and buttons clicked.?

Correct! You don't <have> to do anything with the web page itself. IE
doesn't need to be involved. If you can work out what the URL and posting
behaviour is going to be, you can simulate the whole thing.

Here's an example:

This form will submit a query to Google.
<form method="GET"
action="http://www.google.com/search"
name="frmSearch " >
<input type="text" name="q" value="Foo">
<input type="submit" value=" Search Google ">
</form>

So will this URL:
http://www.google.com/search?q=Foo

This is how easy it is to simulate a GET. The URL has the same effect as
entering the text and clicking the Search button. (You may be able to do the
same with POST data - package it up as if it were a GET - but I haven't tested
this.)

Does this make sense? And could it be of any use to you?
Come back either way.

If it isn't we can work something out the hard way - using actual
programming. And bring examples of your web pages (attached in a zip, please)
and say what you want to happen.

Regards,
Fergus

Nov 20 '05 #2
Cor
Hi MeNotHome,
I am not sure what you want, but you can take a look for "Webbrowser " on
MSDN
Your question can have a lot of answers.
Cor
Nov 20 '05 #3
Yes, I thought of that too.

However, the pages are asp based and some of them do not pass the
information on the cammand line. I watched the address bar carefully
when I stepped from page to page to see if that would work. It would
not.

Any other ideas?

Thanks

On Wed, 24 Sep 2003 01:09:28 +0100, "Fergus Cooney"
<fi******@tesco .net> wrote:
Hi MeNo,

I presume that you have a particular URL in mind.

In that case, take a look at the Html. You'll see where the Forms are and
where your inputs are. The inputs will have a name or an id. The form will
have a submit action - either Post or Get.

The task is to enter the data into the textboxes and click the checkboxes
and buttons, etc, right ?
Well, not quite. Try again.

The task is to get the right values into those inputs and get the Form to
submit?
Still not quite right. Try again.

The task is to call the URL in the way that it <would> be called if the
data <had> been entered and the boxes and buttons clicked.?

Correct! You don't <have> to do anything with the web page itself. IE
doesn't need to be involved. If you can work out what the URL and posting
behaviour is going to be, you can simulate the whole thing.

Here's an example:

This form will submit a query to Google.
<form method="GET"
action="http://www.google.com/search"
name="frmSearch " >
<input type="text" name="q" value="Foo">
<input type="submit" value=" Search Google ">
</form>

So will this URL:
http://www.google.com/search?q=Foo

This is how easy it is to simulate a GET. The URL has the same effect as
entering the text and clicking the Search button. (You may be able to do the
same with POST data - package it up as if it were a GET - but I haven't tested
this.)

Does this make sense? And could it be of any use to you?
Come back either way.

If it isn't we can work something out the hard way - using actual
programming. And bring examples of your web pages (attached in a zip, please)
and say what you want to happen.

Regards,
Fergus


Nov 20 '05 #4
I need to create a browser control in a window. Then within this
browser control access a certain .ASP page and enter various
information and press the submit button.

page 1 is a login and password and press submit.
page 2 is click on three different links in succession
page 3 is enter start date, end date and press submit
page 4 is click a check box and press a another button.

I need this fully automate so a person does not have to do it.
We can put it on a timer and activate two or three times a day.

Thanks for any advice

On Wed, 24 Sep 2003 11:12:44 +0200, "Cor" <no*@non.com> wrote:
Hi MeNotHome,
I am not sure what you want, but you can take a look for "Webbrowser " on
MSDN
Your question can have a lot of answers.
Cor


Nov 20 '05 #5
Hi MeNo,

Are the pages local to you or on the Internet? Could you give us the URLs?
Or zip the web pages and post them?

One approach that I use with mail.com is that I have my own copy of the
login page. I've taken out all the junk and added in some Javascript (called
from body.onload) which sets the username and password fields to my details
and then calls submit. I don't go to mail.com I simply haul my login page into
IE and off it goes.

If you know the content of the pages that you are interested in, you could
do the same. I expect the login page is pretty much static. If the content
changes on the others, you could obtain the pages using the Framework's Net
classes and then insert the appropriate changes textually. Save this to a file
and then it load into your browser (IE or WebBrowser control, whichever) and
off it goes.

Regards,
Fergus

ps. I'm not syaing the get-IE-to-poke-data-and-buttons approach won't work - I
just don't know how to do it.
Nov 20 '05 #6
No, I don't think I should post the page since it is on the internet
and it's password protected.

Thanks for the ideas about creating a personal login page.

I am sure there is a way to access the objects on a web page inside a
webbroswer control. I just need to learn how to do it.

Thanks for any further advice.

On Wed, 24 Sep 2003 14:51:53 +0100, "Fergus Cooney"
<fi******@tesco .net> wrote:
Hi MeNo,

Are the pages local to you or on the Internet? Could you give us the URLs?
Or zip the web pages and post them?

One approach that I use with mail.com is that I have my own copy of the
login page. I've taken out all the junk and added in some Javascript (called
from body.onload) which sets the username and password fields to my details
and then calls submit. I don't go to mail.com I simply haul my login page into
IE and off it goes.

If you know the content of the pages that you are interested in, you could
do the same. I expect the login page is pretty much static. If the content
changes on the others, you could obtain the pages using the Framework's Net
classes and then insert the appropriate changes textually. Save this to a file
and then it load into your browser (IE or WebBrowser control, whichever) and
off it goes.

Regards,
Fergus

ps. I'm not syaing the get-IE-to-poke-data-and-buttons approach won't work - I
just don't know how to do it.


Nov 20 '05 #7
Hi MeNo,

Are the pages local to you or on the Internet? Could you give us the URLs?
Or zip the web pages and post them?

One approach that I use with mail.com is that I have my own copy of the
login page. I've taken out all the junk and added in some Javascript (called
from body.onload) which sets the username and password fields to my details
and then calls submit. I don't go to mail.com I simply haul my login page into
IE and off it goes.

If you know the content of the pages that you are interested in, you could
do the same. I expect the login page is pretty much static. If the content
changes on the others, you could obtain the pages using the Framework's Net
classes and then insert the appropriate changes textually. Save this to a file
and then it load into your browser (IE or WebBrowser control, whichever) and
off it goes.

Regards,
Fergus

ps. I'm not syaing the get-IE-to-poke-data-and-buttons approach won't work - I
just don't know how to do it.


Nov 20 '05 #8
The initial part of the website is fairly static. ie login via user
name and password. Then click a couple of links.

However the important part at the end is very dynamic.

Thanks for any help

On Thu, 25 Sep 2003 02:52:09 +0100, "Fergus Cooney"
<fi******@tesco .net> wrote:
Hi MeNo,

Are the pages local to you or on the Internet? Could you give us the URLs?
Or zip the web pages and post them?

One approach that I use with mail.com is that I have my own copy of the
login page. I've taken out all the junk and added in some Javascript (called
from body.onload) which sets the username and password fields to my details
and then calls submit. I don't go to mail.com I simply haul my login page into
IE and off it goes.

If you know the content of the pages that you are interested in, you could
do the same. I expect the login page is pretty much static. If the content
changes on the others, you could obtain the pages using the Framework's Net
classes and then insert the appropriate changes textually. Save this to a file
and then it load into your browser (IE or WebBrowser control, whichever) and
off it goes.

Regards,
Fergus

ps. I'm not syaing the get-IE-to-poke-data-and-buttons approach won't work - I
just don't know how to do it.


Nov 20 '05 #9
Hi MeNo,

|| Thanks for any help

Are you saying thanks for what I've given or asking for more? ;-)

If more, then please discuss what I've talked about and how much of it you
can or can't use, and then give me some indication of where you want to go.

Regards,
Fergus
Nov 20 '05 #10

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
4820
by: Kate Gibbs | last post by:
I need to write a simple utility in VB.NET that reads an Excel file, gets some data from a sheet, then...it needs to automate internet explorer in a robot manner. I know that Application Centre Test does something like this, but it doesn't support viewstate very well, so I need to write my own application. What I'm really looking for are some managed classes that will allow me to drive IE in a phantom way so that I can
2
1873
by: Heiko Pliefke | last post by:
Hi NG! I have to change dynamically all hyperlinks, when the html-page is loaded at the client. This works fine, except in the following scenario: When the innerText of an anchor contains an '@', the InternetExplorer changes the innerText-Property to the HREF-Property. I have checked this with MoZilla/FireBird and Opera and there is no problem! To explain, what i mean, see following example:
6
4582
by: tinkerman | last post by:
Hello net friends, I need to automate Internet Explorer in a very simple way. I need to: 1. press refresh (F5) on the currently loaded website. 2. press END button. 3. Click a button somewhere on the screen with the mouse left button (I'm not sure this button can be pressed directly via keysequence, not via mouse, but it does have a name).
0
1472
by: satish | last post by:
Hi all, how to automate internet explorer for login and repetitive task using vb.net or c# can anyone provide me links to such websites for free tutorials and source code. Satish
9
7720
by: Etayki | last post by:
Hi! I am new to VB.net and I am using the Visual Basic 2005 Express Edition I have two questions: 1. I am trying to write an application that will automate Internet Explorer and store data in a database. Am I better off learning VB.net or C#.net? Is there a free development environment for C# as well?
2
2229
by: borisov.gleb | last post by:
wp.prototype.loadHtmlToCtrl = function (ctrl, html) { alert(1); ctrl.innerHTML = html; alert(2); } 5-10 seconds between two alerts depends on string length. It's only IE bug. FF and Safari3 works fine. Maybe anyone knows how I can insert huge HTML data faster? (100-400Kb
1
2225
by: JohnathanKong | last post by:
Hello, I hope this is the right place to post, but anyways, here goes. I current have a forum, snitz, in place, but am having an IE specific problem. Basically what happens is, I have a page that drops a cookie which logs in the user. This all works fine, but once the cookie is dropped ALL post method data from forms become empty. Get works, and if I post data to a different site it works, so the break down is reading the data from the post....
1
5027
by: JMANTN | last post by:
I have data that sometimes needs to be uploaded to a 3rd party website and I’m trying to automate this process with Access 2007. I’m having a difficult time with my VBA syntax and with identifying the HTML names/id’s of objects I want to control. I have referenced Microsoft HTML Object Library & Microsoft Internet Controls and should note the version of Internet Explorer my company currently uses is IE6 (I know can’t wait for an update) ...
1
2154
by: sososm | last post by:
Hy experts I need a little help here. Can anybody tell me how to select a radio button from another program knowing the name,id or text of the radio button. I want to automate internet explorer by checking the "First Name" radio button then pressing the "Send" button. This is the code I'm using to get the focus to internet explorer: using System;
0
8315
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
8829
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
8734
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
8608
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
7341
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
5633
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4164
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
1
2733
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
1962
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.