Shantanu Gupta
Shantanu Gupta

Reputation: 21108

"FormatException was unhandled" Input string was not in a correct format

I have an error in my website and trying to resolve: Error "format exception was unhandled" such that it work for both date time as well as with string and integer.

Please see the details and code from this link http://tinyurl.com/ydg3u7s

Thanks

Upvotes: 0

Views: 1204

Answers (2)

Stefan Hendriks
Stefan Hendriks

Reputation: 4801

Perhaps some try/catch mechanism?

Upvotes: 0

NM.
NM.

Reputation: 1929

return Convert.ChangeType(IsThisObjectANull, DataTypeCode);

The conversion is probably failing due to incompatible types . You might have to debug and check when this happens .

Upvotes: 1

Related Questions