delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2004/05/08/15:23:36

Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sources.redhat.com/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sources.redhat.com/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com
X-Authentication-Warning: slinky.cs.nyu.edu: pechtcha owned process doing -bs
Date: Sat, 8 May 2004 15:23:14 -0400 (EDT)
From: Igor Pechtchanski <pechtcha AT cs DOT nyu DOT edu>
Reply-To: cygwin AT cygwin DOT com
To: zzapper <david AT tvis DOT co DOT uk>
cc: cygwin AT cygwin DOT com
Subject: Re: Scripts for calling Internet Explorer,Explorer,Word,Access,Excel from Cygwin
In-Reply-To: <0rkp90dusb7ll3gneurrim73sk27nqdaic@4ax.com>
Message-ID: <Pine.GSO.4.56.0405081516320.8563@slinky.cs.nyu.edu>
References: <0rkp90dusb7ll3gneurrim73sk27nqdaic AT 4ax DOT com>
MIME-Version: 1.0
X-Scanned-By: MIMEDefang 2.39

On Sat, 8 May 2004, zzapper wrote:

> Hi
> With help from this NG have created the following scripts, I think
> they are very useful especially wexp. (Paths to various apps on your
> PC may vary of course). Excepting wexp all require a filename as
> parameter eg > wmdb test.mdb
>
>  wexp  : Launch Windows Explorer with correct "Windows" path
>  wint  : Launch Internet Explorer with correct "Windows" path
>  wop   : Launch Opera with correct "Windows" path
>  wpdf  : Launch Acrobat Reader with correct "Windows" path
>  wxls  : Launch Excel with correct "Windows" path
>  wdoc  : Launch Word with correct "Windows" path
>  wmdb  : Launch Access with correct "Windows" path

David,

I hate to rain on your parade, but have you tried "cygstart"?  If you have
the Explorer file associations set up correctly (i.e., double-clicking on
a .mdb file launches Access, etc), you should simply be able to say

$ cygstart test.mdb

to pop up Access.  Similarly, "cygstart ." (or any other directory) should
pop up Windows Explorer.  You can even say "cygstart -x ." to open Windows
Explorer in "explore" mode.  This should also work with the *full* POSIX
path to a file, whereas your solution requires that the file be in the
current directory...

FWIW, the one useful aspect of your scripts is that you can only associate
the ".html" extension with either Opera or IE, so you'll need a script to
invoke the non-default browser.  Note also that people may have their
programs, notably Opera, Acrobat Reader, etc, installed in different
location from that which you hard-coded into the scripts.

HTH,
	Igor
-- 
				http://cs.nyu.edu/~pechtcha/
      |\      _,,,---,,_		pechtcha AT cs DOT nyu DOT edu
ZZZzz /,`.-'`'    -.  ;-;;,_		igor AT watson DOT ibm DOT com
     |,4-  ) )-,_. ,\ (  `'-'		Igor Pechtchanski, Ph.D.
    '---''(_/--'  `-'\_) fL	a.k.a JaguaR-R-R-r-r-r-.-.-.  Meow!

"I have since come to realize that being between your mentor and his route
to the bathroom is a major career booster."  -- Patrick Naughton

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

- Raw text -


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