Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe@cygwin.com>
List-Archive: <http://sources.redhat.com/ml/cygwin/>
List-Post: <mailto:cygwin@cygwin.com>
List-Help: <mailto:cygwin-help@cygwin.com>, <http://sources.redhat.com/ml/#faqs>
Sender: cygwin-owner@cygwin.com
Mail-Followup-To: cygwin@cygwin.com
Delivered-To: mailing list cygwin@cygwin.com
Message-ID: <3E4BE741.C5A6BDE8@isg.de>
Date: Thu, 13 Feb 2003 19:43:13 +0100
From: Tino Lange <Tino.Lange@isg.de>
Organization: IS Innovative Software AG
X-Accept-Language: de,en,fr
MIME-Version: 1.0
To: Robert Citek <rwcitek@alum.calberkeley.org>
Cc: cygwin@cygwin.com
Subject: Re: NT wrappers
References: <070b01c2d368$ee4bcdc0$9c00140a@uk.circle.com> <F54ukGYk5qqWJJAf8DA0001cbfa@hotmail.com> <070b01c2d368$ee4bcdc0$9c00140a@uk.circle.com> <3.0.5.32.20030213092743.01d5cb88@mail.earthlink.net> <078701c2d376$4fd7a750$9c00140a@uk.circle.com>
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit

Hi!

The "MS way" of scripting applications is generally *not* using the
commandline but using (D)COM.
This can be done via lots of languages, very easy for example with
VBscript.

Your wrapper will look something like that:

set ie = CreateObject("InternetExplorer.Application")
ie.Navigate("http://sources.redhat.com/cygwin/")
READYSTATE_COMPLETE = 4
Do ' wait until page is loaded
 WScript.Sleep 10
Loop Until ie.ReadyState = READYSTATE_COMPLETE
ie.document.body.focus()
OLECMDID_PRINT = 6
OLECMDEXECOPT_DONTPROMPTUSER = 2
ie.execWB OLECMDID_PRINT, OLECMDEXECOPT_DONTPROMPTUSER
WScript.Sleep 5000 ' let ie some time to print before destroying...
ie.quit

But: As Vince wrote this is quite offtopic here...

Cheers

Tino

> ----- Original Message -----

Vince Hoffman wrote:

> Use the source ;) oops you can't.
> umm well if using /? or -? or /h or /help or any variation doesnt work then
> have a search on the net. There is no magic way to find out otherwise. ( To
> be honest you'd do much better asking on an MS related newsgroup/maillist)

> ----- Original Message -----

> From: "Robert Citek" <rwcitek@alum.calberkeley.org>
> To: <cygwin@cygwin.com>
> Sent: Thursday, February 13, 2003 3:27 PM
> Subject: NT wrappers
> 
> >
> > How can I discover what the command line options are to an NT program?
> >
> > I would like to write wrappers around some NT programs so that they are
> > easier to use from bash.  For example, I would like to write a wrapper so
> > that something like this is possible:
> >   $ explorer --print http://sources.redhat.com/cygwin
> > This would use MS Explorer to render the page and print it.  Of course,
> > Explorer is just one example.
> >
> > Regards,
> > - Robert

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Bug reporting:         http://cygwin.com/bugs.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

