private object GetString(object value)
{
if (value is int)
return "I" + ((int) value).ToString(NumberFormatInfo.InvariantInfo);
if (value is float)
return "F" + ((float)value).ToString(NumberFormatInfo.InvariantInfo);
if (value is decimal)
return "M" + ((decimal)value).ToString(NumberFormatInfo.InvariantInfo);
throw new NotSupportedException();
}
}