Mógłby mi ktoś napisać jak to zmodyfikować aby działało

procedure TForm1.FormCreate(Sender: TObject);
begin
DragAcceptFiles(Handle, True);
end;

procedure TForm1.WMDropFiles(var Msg: TWMDropFiles);
var
NazwaPliku: array[0..MAX_PATH] of Char;
begin
if DragQueryFile(Msg.Drop, 0, NazwaPliku, MAX_PATH) > 0 then
begin
plik := NazwaPliku;
tworzenie;
end;
end;