Jump to content

Web Form filler


Recommended Posts

Hi,

Just posting this in case anyone has done something similar so didn't want to try re-inventing the wheel....

We have an internal tracking system which has 3 fields to fill.

I have today been presented with an Excel spreadsheet with over a thousand rows that I need to extract, populate 3 fields on a web page, submit and reload the form and onto the next one.

Does anyone have a suggestion as to the best way of going about this?

To be honest, the bit I am more stuck on is to iterate through the rows then repeat the process for the next one. Last time I did this was in BBC Basic with a GOTO command! LOL

Many thanks

Link to comment
Share on other sites

Hii,

How I would do it,

Convert your exelsheet to a CSV, and load the CSV into your autoit script.

Parse the csv Values, post em to your server with the IE component.

like http://myserver/index.php?lol=val1%lol2=val2

Create a big loop and the jobs almost done.

I lately used this system for a dentist who changed software, my script took 1,5 hour to complete

but the job was done :D

suc6

Link to comment
Share on other sites

Hii,

How I would do it,

Convert your exelsheet to a CSV, and load the CSV into your autoit script.

Parse the csv Values, post em to your server with the IE component.

like http://myserver/index.php?lol=val1%lol2=val2

Create a big loop and the jobs almost done.

I lately used this system for a dentist who changed software, my script took 1,5 hour to complete

but the job was done :D

suc6

Hmmmm sounds good, but can it be done in ASP?

Here is what I have so far

#include <IE.au3>
$oIE = _IECreate ("http://its-server/ITS/addcontact.aspx")
_IELoadWait ($oIE)
$oForm = _IEGetObjByName ($oIE, "ResellerContact")
_IEFormElementSetValue ($oForm, "E-mail address")
$oForm1 = _IEGetObjByName ($oIE, "Reseller")
_IEFormElementSetValue ($oForm1, "Account number")
$oForm2 = _IEGetObjByName ($oIE, "Customer")
_IEFormElementSetValue ($oForm2, "Customer")
Sleep(50)
_IENavigate ($oIE, "http://its-server/ITS/addcontact.aspx")

Pretty vague I know, but after a few basic apps, this is really my first dabble with web pages.

So, I know I need to read my CSV file into an array, to populate my values, but how do I get the values from that? I presume filereadline is the wrong way to go?

Edited by arcticpup
Link to comment
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
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...