Jump to content

Recommended Posts

Posted

i have a problem with one of my script,i try to run an exe file and vbs file under a specific if condition 

i tried      

Run('"process.exe" "1.vbs"') but this doesn't work,any ideas?

  • Moderators
Posted

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!

Posted (edited)

I can run one after the other,for me it's not a problem but i dont know the correct code to do this

Edited by phenomxx4
  • Moderators
Posted

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!

Posted

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

Posted

yes but i want to run statistics.exe in hide mode,this is the reason i use a vbscript. i can run statistics.exe in hidden mode with autoit?

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
  • Recently Browsing   0 members

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