BinaryFormatter Version incompatibility.

G

Guest

I'm getting an annoying exception: BinaryFormatter Version incompatibility.
Expected Version 1.0. Received Version XXXX

I've looked all over the web and everything that discusses this seems to be
associated with web services. Usually indicating that the code is mismatched
with BinaryFormatter and SOAPFormatter objects. Stressing that if you use a
BinaryFormatter on one side you must use one on the other.

Well, I'm only using binary. And I'm not writing a web service. This is a
WinForms app that tries to use serialization to send objects over a tcp
connection. Everything works fine for a while. Then I get the exception. I
can tell if it has to do with the amount of data sent, or the time running,
or what... Seems to happen randomly.

Any thoughts would be greatly appreciated.
 
T

Thomas T. Veldhouse

rlrcstr said:
I'm getting an annoying exception: BinaryFormatter Version incompatibility.
Expected Version 1.0. Received Version XXXX

I've looked all over the web and everything that discusses this seems to be
associated with web services. Usually indicating that the code is mismatched
with BinaryFormatter and SOAPFormatter objects. Stressing that if you use a
BinaryFormatter on one side you must use one on the other.

Well, I'm only using binary. And I'm not writing a web service. This is a
WinForms app that tries to use serialization to send objects over a tcp
connection. Everything works fine for a while. Then I get the exception. I
can tell if it has to do with the amount of data sent, or the time running,
or what... Seems to happen randomly.

Any thoughts would be greatly appreciated.

Any chance the .NET version is different on the server side of the connection
than it is on the client side?
 
G

Guest

And the error is not consistent. Seems to occur maybe after a certain
amount of data, o rmaybe if the data is too large, or if it come to fast,
maybe... I can't quite figure it out...

Jerry
 
T

Thomas T. Veldhouse

And the error is not consistent. Seems to occur maybe after a certain
amount of data, o rmaybe if the data is too large, or if it come to fast,
maybe... I can't quite figure it out...

I suspect that your data is corrupt comming off the TCP stream.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top