[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: launching web browser?
- Subject: Re: launching web browser?
- From: "Mark Rivers" <rivers(at)cars.uchicago.edu>
- Date: Sat, 22 Jul 2000 07:51:45 -0500
- Newsgroups: comp.lang.idl-pvwave
- Organization: The University of Chicago
- References: <8l7cql$fsi$1@ra.nrl.navy.mil>
- Xref: news.doit.wisc.edu comp.lang.idl-pvwave:20375
tb wrote in message <8l7cql$fsi$1@ra.nrl.navy.mil>...
>Anybody got a good solution of how to launch the system default
>web browser? Just doing
>
>spawn, "iexplore.exe"
>or
>spawn, "netscape.exe"
>
>is no good because I don't know if that's their browser, or even
>if those are loaded on the system. They may use some other browser that
>I'm not aware of.
>
>Or.. launch *any* (non-shell, i.e. windowing) app, e.g. Excel.
You spawn the command
"start <URL>" where <URL> is the Web page you want to display.
This is actually quite simple and elegant.
- The start command makes it run in the "background" so that IDL does not
wait for the
browser to exit
- It launches whatever application is associated with URLs, i.e. the default
browser. Note that the
browser must be correctly installed for this to work.
- If there is already a browser running it displays the page on that running
browser. If there
is not already a browser running it will start a new one.
for example:
spawn("start http://cars.uchicago.edu/software/mca.html")
Mark Rivers