Jump to content

Some Questions About One Of My Scripts


Recommended Posts

I am trying to make a script that keeps a IE window minimized and go's to the pages you tell it to with out opening and then saving html to a folder I choose. I can do the downloading the page just haven't started it yet.

So here are my questions about the script below.

$Input = InputBox("Web Address","Address:", "", "",50,50,320,250)
$title1 = "CCS - Microsoft Internet Explorer"
$text = ""
$id = "Edit1"
$id2 = "ToolbarWindow321"
$backspace = "{BS}"
GUICtrlRead($input)
Run( @ProgramFilesDir & "\Internet Explorer\IEXPLORE.EXE", "", @SW_MINIMIZE)
WinWait($title1)
Sleep(1000)
ControlClick($title1, $text, $id, "left", 1)
ControlSend($title1, $text, $id, "http://" & $input & "/")
ControlClick($title1, $text, $id2, "left")

1. Why when it types in my input it types behind my homepage? Example:

http://www.autoitscript.com/http://www.ccs.com/

2.How do I get the whole script to shutdown if I press the "X" button on the inputbox?(I know how to do it with GUI's just not on a plain InputBox :( )

3. Why when it clicks the go button it brings up the window?

Edit: More questions

4. How do I keep the inputbox up?

It's probably easy to do all this, but I can't figure it out. :think:

Thanks.

Edited by bucky002
Link to comment
Share on other sites

My guesses are:

1. Why when it types in my input it types behind my homepage? Example:

http://www.autoitscript.com/http://www.ccs.com/

You have to add CTRL+A to select all the text in the input box.

2.How do I get the whole script to shutdown if I press the "X" button on the inputbox?(I know how to do it with GUI's just not on a plain InputBox :think: )

When you hit the 'X' the input box is closed but you do no checking against $input or @error to see if it was closed.

3. Why when it clicks the go button it brings up the window?

Its not the go button that does that it is the first ControlClick or later. It's possible IE does not like to be clicked when minimized?

Edit: More questions

4. How do I keep the inputbox up?

You cant so you have to create your own if you want it to stay put.
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...