Jump to content

How to Validate data 'OnExit' using ClientEvents?


mhmda

Recommended Posts

Hi... ;)

 

I want to validate input data to edit control at client side using the "clientevents" property on the Form, how can I do that?

 

I want to do this:

procedure TMainForm.UniEdit2Exit(Sender: TObject);
var
a:double;
begin
if ansipos('.',UniEdit2.Text)=0 then
begin
  a:=strtofloat(UniEdit2.Text);
  UniEdit2.Text:=formatfloat('0.00',a);
end;
end;

 

Thank you,

Link to comment
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
×
×
  • Create New...