delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2000/05/02/09:12:43

Mailing-List: contact cygwin-help AT sourceware DOT cygnus DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT sourceware DOT cygnus DOT com>
List-Archive: <http://sourceware.cygnus.com/ml/cygwin/>
List-Post: <mailto:cygwin AT sourceware DOT cygnus DOT com>
List-Help: <mailto:cygwin-help AT sourceware DOT cygnus DOT com>, <http://sourceware.cygnus.com/ml/#faqs>
Sender: cygwin-owner AT sourceware DOT cygnus DOT com
Delivered-To: mailing list cygwin AT sourceware DOT cygnus DOT com
Message-Id: <m12mdQV-000F1SC@nepomuck.mathematik.uni-kl.de>
Date: Tue, 2 May 2000 16:13:27 +0200 (MET DST)
From: Olaf Bachmann <obachman AT mathematik DOT uni-kl DOT de>
To: xemacs-nt AT xemacs DOT org
CC: cygwin AT sourceware DOT cygnus DOT com
Subject: Opening local URL in browser
X-Mailer: VM 6.34 under 20.3 "Vatican City" XEmacs Lucid
Mime-Version: 1.0 (generated by tm-edit 7.108)

From my cygwin application, I'd like to open a local html file in the
default system browser. Looking through the Xemacs sources, I found
the 'ShellExecute' call (in file objects-msw.c). Called from within
Xemacs, it does exactly what I had expected. Duplicating the system
call with exactly the same arguments in my little test program with:
#include <windows.h>
int main()
{
  ShellExecute(NULL, "open", NULL, "index.html", "d:\\home\\obachman\\tmp\\", SW_SHOWDEFAULT);
}

does not bring up the HTML browser, but the FileBrowser with the C: directory
as its contents. The same happens if I play around with the directory
and location of the index.html file and/or the SW_* parameter

Do I still have to call some initialization before ShellExecute works
as expected? What else could I do to open a local URL in a browser?

Thanks for any help,
Olaf

____________________________________________________________________________
Olaf Bachmann              | Phone: + 49-631/205 2738 (work)
Centre for Computer Algebra|	    + 49-6306/7396    (home)
Fachbereich Mathematik     | Email: obachman AT mathematik DOT uni-kl DOT de
Universitaet Kaiserslautern| URL: http://www.mathematik.uni-kl.de/~obachman

--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe AT sourceware DOT cygnus DOT com

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019