Jump to content

Run a vbs file and an exe file at the same time


Recommended Posts

  • Moderators

I guess I am unsure what you are trying to do. AutoIt is not multi-threaded, so it is not going to be able to run multiple processes at the same time. Why do you need to run the executable and the vbscript at the same time, rather than one after the other?

"Profanity is the last vestige of the feeble mind. For the man who cannot express himself forcibly through intellect must do so through shock and awe" - Spencer W. Kimball

How to get your question answered on this forum!

Link to comment
Share on other sites

  • Moderators

Well, that brings up the question of what you're trying to accomplish. Where possible, you do not want to mix languages. It would be best to convert the vbscript to autoit. As far as the executable, is this a system exe or a compiled script? The more you can share about your end goal, the more assistance we can provide

"Profanity is the last vestige of the feeble mind. For the man who cannot express himself forcibly through intellect must do so through shock and awe" - Spencer W. Kimball

How to get your question answered on this forum!

Link to comment
Share on other sites

okay man,i have this piece of code

If $idleTimer > 60000 And Not ProcessExists("process1.exe") Then
      Run("process1.exe") 
   ElseIf $idleTimer < 60001 And ProcessExists("f.exe") Then
      Run("process2.exe")

 

i want the script run process 1 and after it started he run my vbs script. (test.vbs)

this is the code of test.vbs:

Dim sh
Set sh = WScript.CreateObject("WScript.Shell")
sh.run "cmd /K statistics.exe & exit", 0 ,false
Set sh = Nothing

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...