Jump to content

Recommended Posts

You should read the FAQ, particularly question 6. It answers the first part of your question.

$filename = "Mydocument.html" 
run( @ComSpec & " /c start " & $filename,".")
; ---- note the  ^  ^ space characters!

This will open an HTML document using the start command. The advantage to this method is it will automatically use whatever the default web browser is on the computer. Disadvantage is the minimize flag won't work, but you can always use WinSetState() to minimize the window as soon as it appears.

Alternatively, you can specify the browser and add the @SW_MINIMIZE flag, like this:

$filename = "Mydocument.html" 
run("C:\Program Files\Mozilla Firefox\firefox.exe " & $filename,".",@SW_MINIMIZE)

This will open the specified html file in a new minimized FireFox window. Disadvantage is you have to know which browser the person will be using.

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
  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...