Re: AutoSave?

[ Delphi Forum ]

Posted by webmaster Guido on May 05, 2003 at 18:27:11:

In Reply to: AutoSave? posted by Joey on May 03, 2003 at 19:09:58:

: Sorry to be a burden on you guys but i was wondering how would i make say a text box's text or a labels caption save...?

: In the Delphi application which i am making at the moment i would like it so that the user can change a password and then what it has been changed to is recorded so that its the same password if the appi is closed.

: Here is what I have done at the moment just so u get an idea of what i am doin:

: ////////
: procedure TForm1.Button1Click(Sender: TObject);
: begin
: if edit1.text = form2.label1.caption then
: else
: label1.text := 'Invalid Password'
: end;
: ///////

: I would like to know how to make "form2.label1.caption" saved!
: (even if it means writin this str to a file and then calling it again)

: I got lost when writing this so if it makes no sence plz say and i'll re-write it

: Thx

There's a short tutorial about this in DelphiLand's source code section. Have a look in "Code Snips", under "Saving to a text file, reading from a text file" :)

[ Delphi Forum ]