Problem with serialization, between .net v1.0.3705 and v1.1.4322

Problem with serialization, between .net v1.0.3705 and v1.1.4322

Post by TWV0eHRsa » Sat, 15 May 2004 06:41:07


Hi,

I have an applicaction that user .Net Remoting, Serialization and Reflection. I have been using v1.0.3705 and
the application works fine but I have upgrade my .net framework to v1.1.4322, and now I receive this exception

An unhandled exception of type 'System.ArgumentException' occurred in mscorlib.dl

Additional information: Object type cannot be converted to target type

Unhandled Exception: System.ArgumentException: Object type cannot be converted to target type

Server stack trace:
at System.Reflection.RuntimeFieldInfo.InternalSetValue(Object obj, Object val, BindingFlags invokeAttr, Binder binder, CultureInfo culture, Boolean requiresAccessCheck, Boolean isBinderDefault
at System.Runtime.Serialization.SerializationFieldInfo.InternalSetValue(Object obj, Object value, BindingFlags invokeAttr, Binder binder, CultureInfo culture, Boolean requiresAccessCheck, Boolean isBinderDefault
at System.Runtime.Serialization.FormatterServices.SerializationSetValue(MemberInfo fi, Object target, Object value
at System.Runtime.Serialization.ObjectManager.CompleteObject(ObjectHolder holder, Boolean bObjectFullyComplete

If I change to the v1.0.3705 the application works fine. I changed only the .net framework version

Some body can help me

Regards...
 
 
 

Problem with serialization, between .net v1.0.3705 and v1.1.4322

Post by Paul Glavi » Mon, 17 May 2004 18:12:01

Can you provide some code or more details on your problem?

--
- Paul Glavich
Microsoft MVP - ASP.NET




Reflection. I have been using v1.0.3705 and
v1.1.4322, and now I receive this exception:
mscorlib.dll
converted to target type.
Object val, BindingFlags invokeAttr, Binder binder, CultureInfo culture,
Boolean requiresAccessCheck, Boolean isBinderDefault)
System.Runtime.Serialization.SerializationFieldInfo.InternalSetValue(Object
obj, Object value, BindingFlags invokeAttr, Binder binder, CultureInfo
culture, Boolean requiresAccessCheck, Boolean isBinderDefault)
System.Runtime.Serialization.FormatterServices.SerializationSetValue(MemberI
nfo fi, Object target, Object value)
System.Runtime.Serialization.ObjectManager.CompleteObject(ObjectHolder
holder, Boolean bObjectFullyComplete)
the .net framework version.

 
 
 

Problem with serialization, between .net v1.0.3705 and v1.1.4322

Post by Juan Carlo » Fri, 21 May 2004 06:42:27


Hi,

I found the solution to my problem.

On change of version of .net framework something was worng, so when I
run my application, its loaded v1.0.3705 and in my webserver v1.1.4322,
so I added this lines to the app.config file:

<startup>
<requiredRuntime imageVersion="v1.1.4322" version="v1.1.4322" />
</startup>

Regards,

JCarlos!

*** Sent via Developersdex http://www.yqcomputer.com/ ***
Don't just participate in USENET...get rewarded for it!