Error converting JSON to .Net object in asp.net

Unfortunately, none of the proposed solutions solve the real source of the problem. This exception means that your deserializer tries to read from the end of a stream.

The solution is to rewind the stream to the beginning, ie. set the stream.Position = 0; before deserialization.

Also, as the comments mention, if you used a StreamWriter you need to flush it before using the stream.

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)