Delphi中有没有类似于VB中的shell函数的函数,是用来执行已经存在的程序的,请具体说明下,谢谢
来源:百度知道 编辑:UC知道 时间:2024/09/19 16:33:05
用shellexecute吧,如shellexecute(0,'open',pchar(astr),nil,nil,sw_shownormal);
其中astr为另一程序的路径
在users里添加ShellApi
然后用一下代码可以运行windows本身的计算器
ShellExecute(Handle, 'Open', 'calc.exe', '', '', SW_SHOW);
winexec
or shellexecute 这个函数必须引用uses shellapi;
使用CreateProcess这个API函数