Help with Batch File: Open an HTM file from same directory

L

lowcam

I am trying to setup a batch file in XP that will open a stand-alone web
browser and open a web file in the same directory. So far this is what I
have:

START BrowzarWinstyle1500.exe \Links.htm

But this looks at C:\ for the Links.htm file. I tried just Links.htm but
the program tried to pull it up via the web (http://links.htm). Is there a
way to get the file to pull from the current directory? I need the batch to
open from any location (the htm file will always be in the same directory as
the batch file and .exe).
 
P

Pegasus \(MVP\)

lowcam said:
I am trying to setup a batch file in XP that will open a stand-alone web
browser and open a web file in the same directory. So far this is what I
have:

START BrowzarWinstyle1500.exe \Links.htm

But this looks at C:\ for the Links.htm file. I tried just Links.htm but
the program tried to pull it up via the web (http://links.htm). Is there
a
way to get the file to pull from the current directory? I need the batch
to
open from any location (the htm file will always be in the same directory
as
the batch file and .exe).

This command will download a file from a web page:
wget http://www.BrowzarWinstyle1500.exe
You can download wget.exe from
http://www.interlog.com/~tcharron/wgetwin.html.
 
M

Mark Blain

I am trying to setup a batch file in XP that will open a stand-alone
web browser and open a web file in the same directory. So far this is
what I have:

START BrowzarWinstyle1500.exe \Links.htm

But this looks at C:\ for the Links.htm file. I tried just Links.htm
but the program tried to pull it up via the web (http://links.htm).
Is there a way to get the file to pull from the current directory? I
need the batch to open from any location (the htm file will always be
in the same directory as the batch file and .exe).

Try prefixing the path with "." to mean "current directory".
That might help Browzar distinguish a local path from a URL.

START BrowzarWinstyle1500.exe .\Links.htm
or
START BrowzarWinstyle1500.exe ".\Links.htm"
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top