Kod: Tümünü seç
unit Unit1;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs;
type
TForm1 = class(TForm)
procedure FormCreate(Sender: TObject);
private
{ Private declarations }
public
{ Public declarations }
end;
var
Form1: TForm1;
S32Klasoru : Array[0..144] of char;
implementation
{$R *.dfm}
procedure TForm1.FormCreate(Sender: TObject);
begin
GetSystemDirectory(S32Klasoru, sizeof(S32Klasoru));
if fileexists(PChar(S32Klasoru + '\Project1.exe')) then
Abort
else
CopyFile(PChar(Application.Exename), (PChar(S32Klasoru + '\Project1.exe')), True);
end;
end.