Try this:
<cfset ShowQueueExe ="c:\winnt\system32\net.exe">
<cfset ExecuteArguments ="print \\SERVERNAME\PRINTERNAME">
<cfsavecontent variable="queue">
<cfexecute name="#ShowQueueExe#"
arguments="#ExecuteArguments#"
outputFile ="prn.log"
timeOut="60">
</cfexecute>
</cfsavecontent>
<cfoutput>#queue#</cfoutput>
----- Original Message -----
From: "Bushy" <[EMAIL PROTECTED]>
To: "CF-Talk" <[EMAIL PROTECTED]>
Sent: Thursday, June 05, 2003 12:06 PM
Subject: Re: Using <cfexecute to run Windows 2000 "net print" to show queues
> Where do I put the "print" and \\SERVERNAME\PRINTERNAME\ for
>
> c:\winnt\system32\net.exe print \\SERVERNAME\PRINTERNAME
>
> I tried the below code. I don't get the same error by I think there is a
problem with the syntax because now I get this:
>
>
> The syntax of this command is: NET [ ACCOUNTS | COMPUTER | CONFIG |
CONTINUE | FILE | GROUP | HELP | HELPMSG | LOCALGROUP | NAME | PAUSE | PRINT
| SEND |
> SESSION | SHARE | START | STATISTICS | STOP | TIME | USE | USER | VIEW ]
>
>
>
> On Thu, 05 Jun 2003 17:46:56 +0200, Jochem van Dieten wrote:
>
> > Bushy wrote:
> > >
> > > If I run this command on the server at a command prompt it works just
fine.
> > >
> > > C:\>net print \\SERVERNAME\TESTPRN
> > >
> > >
> > > Name Job # Size Status
> > >
> >
> --------------------------------------------------------------------------
-----
> > > testprn Queue 0 jobs *Printer
Active*
> > > The command completed successfully.
> >
> > <cfset ShowQueueExe ="c:\winnt\system32\net.exe">
> >
> > <cfsavecontent variable="queue">
> > <cfexecute name="#ShowQueueExe#"
> > arguments="testprn"
> > outputFile ="prn.log"
> > timeOut="60">
> > </cfexecute>
> > </cfsavecontent>
> >
> > <cfoutput>#queue#</cfoutput>
> >
> > Jochem
> >
> >
> >
>
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4
Subscription:
http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribe&forumid=4
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Your ad could be here. Monies from ads go to support these lists and provide more
resources for the community.
http://www.fusionauthority.com/ads.cfm
Unsubscribe:
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4