Global Date Restriction&MakeDateText in Codeunit 1

I’m trying to apply a global date restriction in the entire application (I’m on a 3.60) Basically I want to block any users trying to enter a date which is smaller than the 01/01/1980 (1st Jan 1980) I started to look at the function MakeDateText in CodeUnit 1 This function seems to be called each time a Date field is VALIDATED. So I thought that’s exactly what I needed since I do not want to waste my valuable time implementing a check on each date field of the entire database. Below is the Custom Code I’ve added Codeunit 1 MakeDateText(VAR DateText : Text[250]) : Integer GLSetup.CheckDate(DateText); // >> Tarek - 25th August 2005 Table 98 - GLSetup // >> Tarek - 25th August 2005 CheckDate(DateTextPAR : Text[250]) IF EVALUATE(DateLOC, FORMAT(DateTextPAR) ) THEN IF DateLOC < 01011980D THEN ERROR(‘Date %1 is incorrect, the date should be greated than the 1st January 1980’, DateLOC); // << Tarek - 25th August 2005 But it does not work really well : 1/ it does not block the user from entering a date below 1980 (even if the error message from the CheckDate function is displayed) 2/ the error message do not appears just after the first validate (it appears after the second validate and shows the previous value not the current one) Has someone got a solution to implement a Global Date Restriction ?

I think, but I do not know fore sure, that this function is used to format a date into a readable textformat, So the date is stored directly in the database and this function is called to display the value Regards, Mark Brummel