|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
Running external exe's
Thi is probly an easy noob question for many of you to answer, but can someone tell how you run an external exe from within a delphi program?
thx plmqaz. |
|
#2
|
|||
|
|||
|
Something like this:
Code:
Uses ShellAPI;
...
ShellExecute("program.exe", "param1 param2 param3", SW_SHOWNORMAL, 0);
(straight from my head - look up the parameter order and meanings in the WinAPI help.) hth, M.
__________________
-- Manuel Hirsch - Linux, FreeBSD, programming, administration articles, tutorials and more. |
|
#3
|
|||
|
|||
|
Thx
Hey cheers for the help,
This is the line of code I used in the end, it's a bit bodged as I don't know what the HWnd property is. Is there any glaring mistakes or possible improvements. (The code is basically ment to reload itself) ShellExecute(AllocateHWnd(WndProc), '', PAnsiChar(Application.ExeName), '', '', 0); thx plmqaz |
|
#4
|
|||
|
|||
|
hWnd is the handle to the parent window. You can use "Application.Handle" here.
![]() M. |
![]() |
| Viewing: Dev Shed Forums > Programming Languages - More > Delphi Programming > Running external exe's |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|