Photo Gallery Member List Search Calendars FAQ Ticket List Log Out


convert batch job to vbs

 
Logged in as: Guest
arrSession:exec spGetSession 2,2,65929
 Active Users: There are 0 members and 0 guests.
 Users viewing this topic: none
 

 

 
  
  Printable Version
All Forums >> [Scripting] >> WSH & Client Side VBScript >> convert batch job to vbs
  Do you like VisualBasicScript.com? Link to us and help spread the word about our forum. Thanks!
Page: [1]
Login
Message << Older Topic   Newer Topic >>
 convert batch job to vbs - 11/4/2008 3:10:03 AM   
  mdlister

 

Posts: 28
Score: 0
Joined: 7/22/2008
Status: offline
Afternoon, i have had a look at converting a script i use to remove software from a pc to a vbs script so i can run the script against a txt file of computers rather than entering them one at a time.

Bat Job is nice and simple, it gets the machine name and passes it to the psexec to run the uninstall on the pc.

PSExec is located in the system32 folder so runs without having to specify the path.


      

Trying to do the same in VBS is more difficult than i imagined


      

can anyone see any problems with the code?

Script starts by using: cscript "RemoveSoftware.vbs" lrq.txt >>results.txt
 
 
Post #: 1
 
 RE: convert batch job to vbs - 11/4/2008 9:25:53 AM   
  dm_4ever


Posts: 2728
Score: 46
Joined: 6/29/2006
From: Orange County, California
Status: offline
Are you getting any errors? What's not working?  If you don't see errors, start by removing the global "On Error Resume Next"

_____________________________

dm_4ever

My philosophy: K.I.S.S - Keep It Simple Stupid
Read Me: http://www.visualbasicscript.com/m_24727/tm.htm
Frequently Asked Stuff: http://www.visualbasicscript.com/m_47117/tm.htm

(in reply to mdlister)
 
 
Post #: 2
 
 RE: convert batch job to vbs - 11/5/2008 1:53:05 AM   
  mdlister

 

Posts: 28
Score: 0
Joined: 7/22/2008
Status: offline
not to worry had a problem with the install files not the script, works a treat for multi uninstalls :)

(in reply to dm_4ever)
 
 
Post #: 3
 
 
 
  

If you found our site useful please link to us <a href="http://www.visualbasicscript.com">VisualBasicScript.com</a>.
All Forums >> [Scripting] >> WSH & Client Side VBScript >> convert batch job to vbs Page: [1]
Jump to:





New Messages No New Messages
Hot Topic w/ New Messages Hot Topic w/o New Messages
Locked w/ New Messages Locked w/o New Messages
 Post New Thread
 Reply to Message
 Post New Poll
 Submit Vote
 Delete My Own Post
 Delete My Own Thread
 Rate Posts