Jump to content

Launching the user's browser


 Share

Recommended Posts

Hi,

try:

RunWait(@ComSpec & ' /c start http://www.mediasync.6te.net/site/index.php?page=download', '', @SW_HIDE)

So long,

Mega

Scripts & functions Organize Includes Let Scite organize the include files

Yahtzee The game "Yahtzee" (Kniffel, DiceLion)

LoginWrapper Secure scripts by adding a query (authentication)

_RunOnlyOnThis UDF Make sure that a script can only be executed on ... (Windows / HD / ...)

Internet-Café Server/Client Application Open CD, Start Browser, Lock remote client, etc.

MultipleFuncsWithOneHotkey Start different funcs by hitting one hotkey different times

Link to comment
Share on other sites

How do I launch the user's browser? I tried:

Run("iexplore.exe http://mediasync.6te.net/site/index.php?page=download")
; and I also tried
Run("http://mediasync.6te.net/site/index.php?page=download")
FYI of knowing why your attempts failed is because 1st, IExplore.exe is not in the systems path and 2nd, Http... is not a file so Run() fails.

:P

Link to comment
Share on other sites

If your using beta open its helpfile and type in IE in the search, theres one called _IECreate:

_IECreate

--------------------------------------------------------------------------------

Create an Internet Explorer Browser window.

#include <IE.au3>

_IECreate ( [$Url = "about:blank" [, $f_tryAttach = 0 [, $f_visible = 1 [, $f_wait = 1 [, $f_takeFocus = -1]]]]] )

Edited by Rad
Link to comment
Share on other sites

FYI of knowing why your attempts failed is because 1st, IExplore.exe is not in the systems path and 2nd, Http... is not a file so Run() fails.

:P

That's not true. Enter iexplore.exe at the Start > Run window and you'll see that it works. Or is that because it's listed in the App Paths?

#include <Process.au3>

$rc = _RunDos("start Http://www.autoitscript.com")

Then what about Firefox? Edited by Pieter

iPod + Online calendars = iPodCALsync

Link to comment
Share on other sites

That's not true. Enter iexplore.exe at the Start > Run window and you'll see that it works. Or is that because it's listed in the App Paths?Then what about Firefox?

It is true. The Run box searches the registry to find Iexplore.exe. If you choose to use @ComSpec with the "Start" command, then it would also search the registry to find Iexplore.exe. The difference with using @ComSpec, without using the Start command, is that it will only search within the path which you tried previously.

I would assume firefox would be found with the above, using the Run box or the Start command, if it were the default browser.

Link to comment
Share on other sites

It is true. The Run box searches the registry to find Iexplore.exe. If you choose to use @ComSpec with the "Start" command, then it would also search the registry to find Iexplore.exe. The difference with using @ComSpec, without using the Start command, is that it will only search within the path which you tried previously.

I would assume firefox would be found with the above, using the Run box or the Start command, if it were the default browser.

Hi,

right. See my post above. That will open the site with the standard browser.

So long,

Mega

Scripts & functions Organize Includes Let Scite organize the include files

Yahtzee The game "Yahtzee" (Kniffel, DiceLion)

LoginWrapper Secure scripts by adding a query (authentication)

_RunOnlyOnThis UDF Make sure that a script can only be executed on ... (Windows / HD / ...)

Internet-Café Server/Client Application Open CD, Start Browser, Lock remote client, etc.

MultipleFuncsWithOneHotkey Start different funcs by hitting one hotkey different times

Link to comment
Share on other sites

... and 2nd, Http... is not a file so Run() fails.

It doesn't need to be a file...if you use the START option:

Run(@ComSpec & " /c start mailto:beansandpotatoes@steak.com?subject=Need%20meat")

Run(@ComSpec & " /c start http://www.steak.com")

One caveat: If trying to pass a URL with *multiple* query string entries you need to put a "^" before each & like this

Run(@ComSpec & " /c start http://www.steak.com?foo=this^&bar=that")

Not sure why that is but I had a time figuring that one out.

These commands will launch whatever the user has defined as their default mail client and web browser.

Edited by sshrum

Sean Shrum :: http://www.shrum.net

All my published AU3-based apps and utilities

'Make it idiot-proof, and someone will make a better idiot'

 

Link to comment
Share on other sites

One caveat: If trying to pass a URL with *multiple* query string entries you need to put a "^" before each & like this

As in PHP?
<?php
; Displays: This is some text '"
echo "This is some text ' \"";
?>
Edited by Pieter

iPod + Online calendars = iPodCALsync

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