p2p.wrox.com Forums

Need to download code?

View our list of code downloads.


Go Back   p2p.wrox.com Forums > Other Programming > VBScript
I forgot my password Register Now
Register | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read
VBScript For questions and discussions related to VBScript.

Welcome to the p2p.wrox.com Forums.

You are currently viewing the VBScript section of the Wrox p2p Programmer to Programmer discussion community. This is a community of more than 40,000 computer programmers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining our free Wrox p2p community you can post your own programming questions and respond to other programmers’ questions. Registered users also don't have to see the ads that are displayed to guests. Registration is fast, simple and absolutely free so please, join today!
Join today and post to win prizes! Post more to increase your chances of being Wrox’s top poster of the month.

Reply
 
Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old September 2nd, 2004, 08:25 AM
Friend of Wrox
Points: 656, Level: 9
Points: 656, Level: 9 Points: 656, Level: 9 Points: 656, Level: 9
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: May 2004
Location: , , .
Posts: 212
Thanks: 0
Thanked 0 Times in 0 Posts
Default Safe For Scripting

Hi,

I have this VBscript which allows you to add a network printer. However because it calls an activeX object it errors out. Can I mark it Safe For Scripting? Here is the script:

<package>
<job id = "jobvbs">
<script language ="VBScript">
Set WshNetwork = CreateObject("WScript.Network")
PrinterPath = "\\TSCL02919\CL-Customer Services"
WshNetwork.AddWindowsPrinterConnection PrinterPath
MsgBox("Customer Services Printer Added!")
history.back(1)
</script>
</job>
</package>


Cheers
interrupt

__________________
\'sync\' &lt;cr&gt;
The name specified is not recognized as an internal or external command, operable program or batch file.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Reddit!
Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
visual source safe sarah lee BOOK: Professional Portal Development with Open Source 0 January 3rd, 2007 09:46 AM
md5() safe??? foddie PHP How-To 0 December 30th, 2005 10:25 PM
Is it safe to use pwdencrypt and pwdcompare pinkuisadear SQL Server 2000 4 February 18th, 2005 08:50 AM
Are you using Visual Source Safe? xgbnow Pro VB 6 9 February 9th, 2004 06:31 PM
Thread safe ejbs Indian Ocean J2EE 0 September 20th, 2003 04:55 PM



All times are GMT -4. The time now is 06:51 PM.


Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
© 2008 Wiley Publishing, Inc