Solved

How to identify a given VBScript from others on Process List??

Posted on 2008-10-19
6
255 Views
Last Modified: 2012-05-05
I have quite a few VB Scripts running concurrently; the whole set is duplicated on several PCs, all running conncurrently on all PCs.  Most of the PCs are free running, and occassionally I check in on them using LOGMEIN.COM.  Occassionally there is a problem with one script and I need to just kill it off the Process list and restart it.  But I do not know which {wscript] entry on the Process list is which.  Is there a way to name a script so that it is identifiable on the list?

Alternatively (maybe preferrrably), a way to make a script that kills a certain script?  If so I would just make a selection of script killers.

OS = Vista Biz 32
0
Comment
Question by:Mike Caldwell
  • 3
  • 3
6 Comments
 
LVL 8

Expert Comment

by:Wikkard
ID: 22753747
No, because your vbscript is running inside cscript there is no easy way of distinguishing it from any other script. Perhaps you could have each script determine its own process Id (PID) and then write that to a log of some sort.
I would suggest you look into creating executables from your scripts, this would be fairly easy to do. This would allow you to name each one as needed.
0
 
LVL 1

Author Comment

by:Mike Caldwell
ID: 22753778
"Executable"??  I am getting progressively handier at VBScript, but do not want to get into VB.  Is that what you meant?  Is it possible there is some sort of 'compiler' that will take a VB script and spit out a VB program?
0
 
LVL 8

Accepted Solution

by:
Wikkard earned 500 total points
ID: 22753882
Thats what I mean, you could compile your vbscripts with very few modifications as vb6 executables.

See http://www.experts-exchange.com/Programming/Q_21302725.html.

A quick search in google for 'vbscript compiler' showed a number of utilities (some freeware some not) which can do this.

0
Enterprise Mobility and BYOD For Dummies

Like “For Dummies” books, you can read this in whatever order you choose and learn about mobility and BYOD; and how to put a competitive mobile infrastructure in place. Developed for SMBs and large enterprises alike, you will find helpful use cases, planning, and implementation.

 
LVL 1

Author Comment

by:Mike Caldwell
ID: 22753983
Wikkard: wow, thanks.  I had no idea such were available.  VBS2EXE looks quite good, and is a whopping nine bucks.  I'll give it a go.

Do you think the EXE file will execute faster than the VBS?
0
 
LVL 1

Author Closing Comment

by:Mike Caldwell
ID: 31507649
Thanks for being so timely.

Mike
0
 
LVL 8

Expert Comment

by:Wikkard
ID: 22754189
It may run a little faster, it all depends how the converter utility (vbs2exe for example) works internally.

If they actually convert the code to native code then it could run faster depending on what the scripts actually do.
0

Featured Post

Comprehensive Backup Solutions for Microsoft

Acronis protects the complete Microsoft technology stack: Windows Server, Windows PC, laptop and Surface data; Microsoft business applications; Microsoft Hyper-V; Azure VMs; Microsoft Windows Server 2016; Microsoft Exchange 2016 and SQL Server 2016.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Introduction During my participation as a VBScript contributor at Experts Exchange, one of the most common questions I come across is this: "I have a script that runs against only one computer. How can I make it run against a list of computers in …
I'm a big fan of Windows' offline folder caching and have used it on my laptops for over a decade.  One thing I don't like about it, however, is how difficult Microsoft has made it for the cache to be moved out of the Windows folder.  Here's how to …
The Task Scheduler is a powerful tool that is built into Windows. It allows you to schedule tasks (actions) on a recurring basis, such as hourly, daily, weekly, monthly, at log on, at startup, on idle, etc. This video Micro Tutorial is a brief intro…
Two types of users will appreciate AOMEI Backupper Pro: 1 - Those with PCIe drives (and haven't found cloning software that works on them). 2 - Those who want a fast clone of their boot drive (no re-boots needed) and it can clone your drive wh…

777 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question