delphi获取程序所在目录
procedure TForm1.Button1Click(Sender: TObject,',',');
begin
ShowMessage(ExtractFilePath(ParamStr(0)),',','); //获取程序所在目录
ShowMessage(ExtractFilePath(Application.ExeName),',','); //获取程序所在目录
ShowMessage(GetCurrentDir + '\',',','); //获取当前目录
end
关键字词: