Subject: Re: NT wrappers
From: Tino Lange <[email-masked]>
To: Robert Citek <[email-masked]>
Cc: [email-masked]
Date: Thu, 13 Feb 2003 19:43:13 +0100

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" <[email-masked]>
> To: <[email-masked]>
> 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/