procedure TForm1.HentFil; var F: TextFile; begin if OpenDialog1.Execute then begin AssignFile(F, OpenDialog1.Filename); Reset(F); ReadLn(F, Password); CloseFile(F); end; end;