Sign in to follow this  
Followers 0
erikson

Read line and execute browser

3 posts in this topic

Hello,

i`m trying to make a script witch to open step by step a list of internet pages. 

So, the file looks like this:

 

http://localhost/products1.html
http://localhost/products2.html
http://localhost/products3.html
http://localhost/products4.html

i need to open all the lines, but not in the same time. More exactly : i need to open chrome, open the first link in file, send some keystrokes, wait for few seconds ( for the data to be entered ) close the tab, and open the same link, do the same, and so on ..

 

Can you give me some guidelines ?

 

Thanx in advice

Share this post


Link to post
Share on other sites



SheelExecute will work if chrome is the default browser
About the keystrokes... good luck  :)

Share this post


Link to post
Share on other sites

so, i made this

the problem is that the browser will open all the links from the file at the same time. I need to open one by one

#include <File.au3>
$file = "c:\file.txt"
FileOpen($file, 0)

    run ($chrome)

For $i = 1 to _FileCountLines($file)
    $line = FileReadLine($file, $i)
ShellExecute("chrome.exe", $line,"","")

FileClose($file)

 

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  
Followers 0