Solved

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

Posted on 2008-10-19
6
240 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
Enabling OSINT in Activity Based Intelligence

Activity based intelligence (ABI) requires access to all available sources of data. Recorded Future allows analysts to observe structured data on the open, deep, and dark web.

 
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

Enabling OSINT in Activity Based Intelligence

Activity based intelligence (ABI) requires access to all available sources of data. Recorded Future allows analysts to observe structured data on the open, deep, and dark web.

Join & Write a Comment

Suggested Solutions

Welcome, welcome!  If you are new to the series and haven't been following along, please take a brief moment to review the first three installments: Part 1 (http://www.experts-exchange.com/Programming/Languages/Visual_Basic/VB_Script/A_266-VBScri…
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…
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

746 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

Need Help in Real-Time?

Connect with top rated Experts

7 Experts available now in Live!

Get 1:1 Help Now