29. Januar 2009 16:14
MakeDateText(VAR DateText : Text[250]) : Integer
Position := 1;
Length := STRLEN(DateText);
ReadCharacter(' ',DateText,Position,Length);
IF NOT FindText(PartOfText,DateText,Position,Length) THEN BEGIN
//- Änderung Datumstest
IF EVALUATE(DateVariable,DateText) THEN BEGIN
EVALUATE(DateVariable,DateText)
END;
IF (DateVariable <01011754D) OR (DateVariable >010112D) THEN BEGIN
IF DateVariable<>0D THEN BEGIN
ERROR(Text1000,FORMAT(DateVariable));
DateText:=FORMAT(TODAY);
CLEAR(DateVariable);
END;
END;
//+ TestÄnderung Datumstest
EXIT(0);
END;
CASE PartOfText OF
COPYSTR(Text005,1,STRLEN(PartOfText)):
Date := TODAY;
COPYSTR(Text006,1,STRLEN(PartOfText)):
Date := WORKDATE;
ELSE
EXIT(0);
END;
Position := Position + STRLEN(PartOfText);
ReadCharacter(' ',DateText,Position,Length);
IF Position > Length THEN BEGIN
DateText := FORMAT(Date);
EXIT(0);
END;
EXIT(Position);
30. Januar 2009 17:37
30. Januar 2009 18:18