Jump to content

Bringing up Internet Explorer


Recommended Posts

It is easy to bring up windows like notepad and excel but does anyone know how to bring up Firefox, Internet Explorer or Google Chrome? And suppose you want to type in some code which is the same thing as going to a certain website or clicking on some link or or entering something in a search bar without actually using a mouse.

Thanks.

 

Link to comment
Share on other sites

Hi,

Maybe like this?

ShellExecute("chrome.exe", "");chrome
ShellExecute("chrome.exe", "http://www.google.com");chrome opening google
ShellExecute("firefox.exe", "");firefox
ShellExecute("iexplore.exe", "");internet explorer

Cheers

Old Scriptology

Visual Ping 1.8 - Mass Ping Program with export to txt delimited.

Desktop 2 RGB and YMCK - Pick a color in the desktop and get the RGB and YMCK code.

Desktop 2 RGB - Pick a color in the desktop and get the RGB code.

ShootIT 1.0 - Screen Capture full and partial screen

[font="'Arial Black';"]Remember Remember The Fifth of November.[/font]

Link to comment
Share on other sites

Thanks Shane0000 and November.

I am able to bring up the window and go to where I want:

$IEapplo =_IECreate("http://wwwin-eng.cisco.com/Eng/INSBU/Hardware/")
_IELinkClickByText($IEapplo, "FPGA_Releases")
_IELinkClickByText($IEapplo, "CheckOut", 0)

However there is a Windows Security Window that pops up. I end up having to manually type in the username and password. I want to use autoit to put in the username and password by itself. I am stuck on how to send in that information.

Is there a way of grabbing hold of the handle which points to the object or is there a way of obtaining that object? I want to write to that security window. 

Link to comment
Share on other sites

Thanks JLogan3123. I can familiarize myself with UDF but there is something else I am trying.

I am leaving out the ControlSend command and put it as a comment because it contains a password.

I first tried this:

Local $IEapplo = _IECreate("http://wwwin-eng.cisco.com/Eng/INSBU/Hardware/")
WinWait("Windows Security", "", 100)
;ControlSend

_IELinkClickByText($IEapplo, "FPGA_Releases", 0, 0)
_IELinkClickByText($IEapplo, "CheckOut", 0, 0)
WinWait("Windows Security", "", 100)

;Control Send

The text I typed in ControlSend was not coming up which seems to suggest that the WinWait command is not causing autoit to recognize the window.

I changed the _IECreate command to include a parameter 0 so it would not wait before returning:

Local $IEapplo = _IECreate("http://wwwin-eng.cisco.com/Eng/INSBU/Hardware/", 0, 1, 0)
WinWait("Windows Security", "", 100)
;ControlSend

_IELinkClickByText($IEapplo, "FPGA_Releases", 0, 0)
_IELinkClickByText($IEapplo, "CheckOut", 0, 0)
WinWait("Windows Security", "", 100)

;Control Send

Now the first ControlSend command works out but the but the _IELinkClickByText stops working. _IELinkClickByText only works if I leave out the WinWait. I know WinWait pauses the script but I thought I added a timeout of 100ns so after the timeout is not supposed to execute the rest of the script?

I appreciate anyone's feedback

Link to comment
Share on other sites

I thank you for your suggestion JohnOne, but I am not convinced about that just yet. It looks like I the problem is with the WinWait. The rest of the script does not execute even though I added a timeout value. Is there something I am not understanding about the WinWait?

Link to comment
Share on other sites

As I understand the security window is designed to resist automation.

I thank you for your suggestion JohnOne, but I am not convinced about that just yet..

 

Try this; copy some text (any piece of text) into the clipboard, and try to paste it into the username and/or password fields of this Windows Security dialog box. If it works, there's obviously something wrong with your code, but I strongly doubt that you will receive any assistance from this forum about how to bypass a Windows Security dialog box, legit use or not.. If it doesn't work, I'd suggest you read JohnOne's post again and then become convinced. B)

- Bruce /*somdcomputerguy */  If you change the way you look at things, the things you look at change.

Link to comment
Share on other sites

The problem has been solved. This code works out. I did an _IELoadWait command and managed to bypass the dialogbox.

Local $IEapplo = _IECreate("http://wwwin-eng.cisco.com/Eng/INSBU/Hardware/", 0, 1, 0)
WinWait("Windows Security", "", 1000)
ControlSend("Windows Security", "", "[CLASS:Edit; INSTANCE:1]", "username{TAB}password{ENTER}")
_IELoadWait($IEapplo)

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...