function IsInteger(value:variant):Boolean;
  var
     temp, errorPos :integer;
  begin
      Val(Value, temp, errorPos);
      if errorPos = 0 then
         result :=(temp-round(temp))=0;
 end;
 
 
 function IsFloat(value:variant):Boolean;
  var
     temp, errorPos :integer;
  begin
      Val(Value, temp, errorPos);
      result := (errorPos = 0);   
  end;