public static decimal ToDecimal(this object foo) { if (foo.IsNull()) return 0; else return Convert.ToDecimal(foo); }