Advertisement

03.29.2006 at 09:04AM PST, ID: 21793847
[x]
Attachment Details
[x]
The Solution Rating System

With so many solutions, how can you tell which solutions are most likely to help you and which ones are not? To provide you with a tool to use, we rate our solutions based on various elements that most accurately determine if a solution is a quality solution. To explain what factors affect the solution rating, here are the elements we take into consideration when formulating our solution rating.

  • The Grade of the Solution
  • The Zone Rank of the Expert Providing the Solution
  • The Number of Author and Expert Comments
  • The Number of Experts Contributing
  • The Feedback of the Community

Your Input Matters
Because of the way the system is set up, the most important variable in this equation is you. As a member of Experts Exchange, you are able to cast your vote on the quality of the solutions in regard to how complete, accurate, helpful and easy to understand each solution is. When you provide your feedback, each rating is adjusted accordingly. So, if you see a solution that has a poor rating that you think is a good solution, let us know by rating it. As you do, the rating will be adjusted and will become more accurate for other members of our site.

If you have any suggestions that you would like to make for our rating system, please ask a question in the Suggestions Zone of Community Support.

Thank you!

7.0

How do I make this script run 5 times and then end.

Asked by LutherB40 in Visual Basic Programming

I have tried putting in a Do script but haven't been able to make it run 5 times and then quit. Can somebody help me with it....


On Error Resume Next

' EXCEPTION PROGRAM TERMINATION
Dim arrExceptions(1)
Set fso = CreateObject("scripting.FileSystemObject")
Set wshnetwork = CreateObject("wscript.network")
On Error Resume Next


arrExceptions(0)="EXCEPTED CPU"

exception=False
For each name in arrExceptions
     If ucase(wshNetwork.Computername) = ucase(name) Then
          WScript.Quit(0)
          exception=True
     Else
     End If
next

If exception Then
Else
     Call KillProcess(wshnetwork.computername)
'     Call ListSoftware(wshnetwork.computername)
End If


Function KillProcess(strComputer)
dim arrProcessList(4)
arrProcessList(0) = "TSWebSvc.exe"
arrProcessList(1) = "Worun32.exe"
arrProcessList(2) = "Worun32.exe"
arrProcessList(3) = "Worun32.exe"

Set objWMIService = GetObject("winmgmts:{impersonationLevel=impersonate}!\\" & strComputer & "\root\cimv2")
Set colProcesses = objWMIService.ExecQuery("Select * from Win32_Process")


For Each objProcess In colProcesses
     For Each strBadProcess In arrProcessList
          If ucase(objProcess.name)=ucase(strBadProcess) Then
               term=objprocess.terminate()
               If term=0 Then
' "Terminated Process "
               Else  
' " Found and NOT terminated"  

               End If      
          Else      
          End If
     Next
Next
End Function  

wscript.sleep 1000

WScript.Quit(0)Start Free Trial
[+][-]03.29.2006 at 09:06AM PST, ID: 16323633

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 14-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]03.29.2006 at 11:31AM PST, ID: 16325318

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 14-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]03.29.2006 at 01:45PM PST, ID: 16326882

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 14-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]03.29.2006 at 01:53PM PST, ID: 16326976

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 14-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]03.29.2006 at 04:22PM PST, ID: 16328099

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 14-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]03.30.2006 at 12:09AM PST, ID: 16330235

View this solution now by starting your 14-day free trial. Setting up your free trial is quick, easy, and secure. We will return you to this solution, unlocked, when you're done.

 

About this solution

Zone: Visual Basic Programming
Sign Up Now!
Solution Provided By: 2Angel
Participating Experts: 2
Solution Grade: A
 
 
[+][-]03.30.2006 at 12:22AM PST, ID: 16330290

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 14-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]05.01.2006 at 01:35PM PDT, ID: 16580495

Experts Exchange has a courteous staff of administrators who help members get the most out of the website by means of administrative comments like this one.

Start your 14-day free trial to view this Administrative Comment or ask the Experts your question.

 
[+][-]05.07.2006 at 12:33PM PDT, ID: 16626268

Experts Exchange has a courteous staff of administrators who help members get the most out of the website by means of administrative comments like this one.

Start your 14-day free trial to view this Administrative Comment or ask the Experts your question.

 
[+][-]05.11.2006 at 01:34AM PDT, ID: 16656322

Experts Exchange has a courteous staff of administrators who help members get the most out of the website by means of administrative comments like this one.

Start your 14-day free trial to view this Administrative Comment or ask the Experts your question.

 
 
Loading Advertisement...
20081112-EE-VQP-43