Jump to content
oORaZvANOo

Ajutor CMD

Recommended Posts

Posted

Salut.

Cum pot face un script cmd sa porneasca singur odata ce este deschis un proces exe

De ex : am programul eu.exe si fisierul tu.cmd ... Daca ponreste eu.exe atunci sa porneasca si tu.cmd

Exista vreo modalitate sa fac acest lucru??

Posted (edited)

Poi daca exe-ul e un programel facut de tine modifica codul sursa sa porneasca cmd-ul respectiv odata cu programul.Daca e altceva atunci fara alt cmd din care sa le pornesti pe ambele nu cred ca ai cum altfel.


@Echo off
call "C:\eu.exe"
call "C:\tu.cmd"
exit

Edited by middleftw
  • Active Members
Posted (edited)

Ceva de genul. Nu e testat, dar ar trebui sa mearga :)


@ echo off

:search
tasklist|find "eu.exe"
IF %ERRORLEVEL% = 0 THEN (GOTO found)
TIMEOUT /T 1
GOTO search

:found
start D:\calea_catre_fisierul_bat

Edited by MrGrj

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.



×
×
  • Create New...