Project JEDI - Issue Tracker
Mantis Bugtracker

Viewing Issue Simple Details Jump to Notes ] View Advanced ] Issue History ] Print ]
ID Category Severity Reproducibility Date Submitted Last Update
0005017 [JEDI VCL] 04 Feature Request feature N/A 2009-11-14 12:41 2011-09-21 14:10
Reporter chickenrudi View Status public  
Assigned To AHUser
Priority normal Resolution fixed  
Status resolved   Product Version 3.38
Summary 0005017: TJvMaskEdit: Don't validate on exit
Description I am currently using TJvMaskEdit and was wondering why the validation already happens when just leaving focus.

In a dialog for entering a registration number (or activation number or similar) if there is a cancel button no validation should happen.

The validation already happens in the Borland sources. TJvMaskEdit at the end is derived from Borland's TMaskEdit.

I solved this problem by writing a new WindowProc:

<code>
TForm1 = class(TForm)
...
FOldWindowProc: TWndMethod;
...
procedure ExitProc(var Msg: TMessage);
...
end;

procedure TForm1.ExitProc(var Msg: TMessage);
begin
  if (Msg.Msg <> CM_EXIT) then
    FOldWindowProc(Msg);
end;

procedure TForm1.FormShow(Sender: TObject);
begin
  FOldWindowProc := JvMaskEdit1.WindowProc;
  JvMaskEdit1.WindowProc := MyWindowProc;
end;
</code>

It would be fine if the component had a property like "ValidateOnExit" that would do exactly what I did in my form.

Ruediger
Additional Information
Tags No tags attached.
Attached Files

- Relationships

-  Notes
(0016935)
obones (administrator)
2009-12-04 15:12

Thanks for this. I'm not sure that using a new window proc is desirable, someone will review that change
(0018235)
AHUser (developer)
2010-11-30 22:21

Fixed in svn revision 12947.

There is now a new published property CheckOnExit: Boolean default True.

- Issue History
Date Modified Username Field Change
2009-11-14 12:41 chickenrudi New Issue
2009-12-04 15:12 obones Note Added: 0016935
2009-12-04 15:12 obones Status new => acknowledged
2010-11-30 22:21 AHUser Note Added: 0018235
2010-11-30 22:21 AHUser Status acknowledged => resolved
2010-11-30 22:21 AHUser Fixed in Version => Daily / SVN
2010-11-30 22:21 AHUser Resolution open => fixed
2010-11-30 22:21 AHUser Assigned To => AHUser
2011-09-21 14:10 obones Fixed in Version Daily / SVN => 3.45


Mantis 1.1.6[^]
Copyright © 2000 - 2008 Mantis Group
Powered by Mantis Bugtracker