[Last Call] Learn how to a build a cloud-first strategyRegister Now

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 3470
  • Last Modified:

Need examples of browser manipulation in AutoIT

I want to create code with the algorithim below in AutoIT. I am using ie7.

500 for working code, 250 for an answer that helps me write my own code.


If window  with myURL is showing then
     Exit
End if

Create a new Ie Window with the blank url
wait for it to be ready
Invoke my browser URL
hide the tool bar
hide the status bar
maximize
make it visible
exit
0
Christopher Schene
Asked:
Christopher Schene
  • 4
  • 2
2 Solutions
 
Christopher ScheneSystem Engineer/Software EngineerAuthor Commented:
increase points
0
 
matrixnzCommented:
Just change out Google for whatever the Title of your page is and also the url for it to navigate to.

Cheers
#NoTrayIcon
#include <IE.au3>
If WinExists('Google') Then Exit

$IE_OBJECT = _IECreate('about:blank', 0, 1, 1, 1)
$IE_HANDLE = _IEPropertyGet($IE_OBJECT, 'hwnd')
	WinSetState($IE_HANDLE, '', @SW_MAXIMIZE)
_IEPropertySet($IE_OBJECT, 'toolbar', False)
_IEPropertySet($IE_OBJECT, 'statusbar', False)
_IENavigate($IE_OBJECT, 'www.google.com', 1)

Open in new window

0
 
Christopher ScheneSystem Engineer/Software EngineerAuthor Commented:
I am working on this.,,,stand by for points
0
Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
Christopher ScheneSystem Engineer/Software EngineerAuthor Commented:
this test does not seem to work:

If WinExists('Google') Then Exit

as it brings up a new google window each time
0
 
matrixnzCommented:
I just put that title in as a test, since Google is region specific, assumed you were going to enter your own url and title.  YouTube would probably be a better example see below:
Basically the Title in "WinExists" reads from left to right so you need to enter in the full title name or a partial name of the Window, so for YouTube you could use "YouTube", "YouT" or even "You", however this is looking at the title of all open windows so it's best to be as specific as possible.
 
#NoTrayIcon
#include <IE.au3>
If WinExists('YouTube') Then Exit

$IE_OBJECT = _IECreate('about:blank', 0, 1, 1, 1)
$IE_HANDLE = _IEPropertyGet($IE_OBJECT, 'hwnd')
	WinSetState($IE_HANDLE, '', @SW_MAXIMIZE)
_IEPropertySet($IE_OBJECT, 'toolbar', False)
_IEPropertySet($IE_OBJECT, 'statusbar', False)
_IENavigate($IE_OBJECT, 'www.youtube.com', 1)

Open in new window

0
 
Christopher ScheneSystem Engineer/Software EngineerAuthor Commented:
I have been on holiday away from my computer for the last week....thanks for your patience
0

Featured Post

New feature and membership benefit!

New feature! Upgrade and increase expert visibility of your issues with Priority Questions.

  • 4
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now