Hi.
I am trying to check
if a date is valid without raising a runtime error, but I cant seem to work it
out.
This is the code I
am trying
try
strtodate(s_value);
except
on EConvertError do
begin
showmessage('The date "' + s_value + '" must be entered in the format dd/mm/yy');
b_ok := false;
end;
end;
strtodate(s_value);
except
on EConvertError do
begin
showmessage('The date "' + s_value + '" must be entered in the format dd/mm/yy');
b_ok := false;
end;
end;
however this raises
a runtime error when the date is invalid as well as displaying my error
message.
Is there any way to
lose the runtime error message and solely display my error
message?
Cheers
Chris
Veale
______________________________________________________
The contents of this e-mail are privileged and/or confidential to the
named recipient and are not to be used by any other person and/or
organisation. If you have received this e-mail in error, please notify
the sender and delete all material pertaining to this e-mail.
______________________________________________________
---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.385 / Virus Database: 217 - Release Date: 4/09/02