TimeStamp Function
function addTimeStamp(in_str:String):String;
var
myDate : TDateTime;
myYear, myMonth, myDay, myHour, myMin, mySec , mymilli : Word;
time_stamp:String;
begin
myDate := Now;
DecodeDateTime(myDate, myYear, myMonth, myDay, myHour, myMin, mySec, mymilli);
time_stamp := Format('%0.4d',[myYear])+ //yyyy
Format('%0.2d',[myMonth])+ //mm
Format('%0.2d',[myDay])+
'T'+
Format('%0.2d',[myHour])+
Format('%0.2d',[myMin])+
Format('%0.2d',[mySec]);
result := in_str+time_stamp;
end;