473,408 Members | 2,888 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,408 software developers and data experts.

dotnet remoting datatable compression issue

hi,

Please refer this article because that is the dll iam using for
compression/decompression of datatables.
http://www.eggheadcafe.com/articles/20031219.asp
This is a windows application in C# & iam using remoting extensively for
my
database layer.

In the remote server iam having a method which returns byte[] instead of
datatable using the compression logic mentioned in the article.

The code is below,

PAB.CompressDataSet.Wrapper objCompressData = new
PAB.CompressDataSet.Wrapper() return return
objCompressData.CompressDataTable(
objData.ExecQryRetDT("sp_name",CommandType.StoredP rocedure,colParams));

The above code returns a compressed byte array.

Now in the client side . i decompress it & convert it to datatable.

PAB.CompressDataSet.Wrapper objUnCompress = new
PAB.CompressDataSet.Wrapper();
DataTable
dtTable=objUnCompress.DecompressDataTable(obj.Exec QryRetDT("sp_name",Com
mandType.StoredProcedure,colParams));
It is during ths conversion i receive a serializationexception & that
too in
most machines. But in some machines it works for atleast one remoting
server. It is quite a strange thing.

THis compressdataset dll mentioned in the article does not have source
code
..
U can visit http://www.eggheadcafe.com/articles/20040311.asp
which has the source code fr ths dll

I even ran the source referencing ths new dll & i found out it is in
wrapper.cs class the exception is happenning & it is when the stream is
being deserialized using the compactformatter.cs.
This is the exact method where the error occurs
private object Deserialize(Stream Wire,ref Object parent) method
& at ths line
InnerList[i].SetValue(Answer,Deserialize(Wire,ref Temp));
Error Stack information is below,

"Object type cannot be converted to target type." }
[System.ArgumentException]: {"Object type cannot be converted to target
type." }
System.Object: {System.ArgumentException}
_className: null
_COMPlusExceptionCode: -532459699
_exceptionMethod: {undefined value>
_exceptionMethodString: null
_helpURL: null
_HResult: -2147024809
_innerException: { }
_message: "Object type cannot be converted to target type."
_remoteStackIndex: 0
_remoteStackTraceString: null
_source: null
_stackTrace: {System.Array}
_stackTraceString: null
_xcode: -532459699
_xptrs: 0
HelpLink: null
HResult: -2147024809
InnerException: { }
Message: "Object type cannot be converted to target type."
Source: "mscorlib"
StackTrace: " at
System.Reflection.RuntimeFieldInfo.InternalSetValu e(Object obj, Object
val,
BindingFlags invokeAttr, Binder binder, CultureInfo culture, Boolean
requiresAccessCheck, Boolean isBinderDefault)\r\n at
System.Reflection.RuntimeFieldInfo.SetValue(Object obj, Object val,
BindingFlags invokeAttr, Binder binder, CultureInfo culture)\r\n at
System.Reflection.FieldInfo.SetValue(Object obj, Object value)\r\n at
Serialization.Formatters.CompactFormatter.Deserial ize(Stream Wire,
Object&
parent) in
F:\\Projects\\project_offline_compress\\CompressDa taSet\\CompactFormatte
r.cs:line
670"
TargetSite: {System.Reflection.RuntimeMethodInfo}
Can u please help me on this because i think some small mistake in the
compactformatter code is resultin in this error.

Let me know if u need any further information.

Thanks,
Pavan
*** Sent via Developersdex http://www.developersdex.com ***
Nov 17 '05 #1
0 1402

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Orly Junior | last post by:
Gentlemen, I am working with .Net Remoting, but I am running into many problems. Probably due to the fact that I am not very experienced with that new technology. The question is... after...
0
by: Markus Minichmayr | last post by:
Hello! I already posted this issue on the remoting NG, but didn't get an answer, so I try it here. I have a client/server app., that communicates via .NET remoting and I need to transport...
40
by: Eitan | last post by:
Hello, I know Java-Applet (written for JBuilder). I would like to know about dotnet technology, pros and cons in comparation to Java-Applet technololgy. Can I write a program in dotnet, like...
3
by: Deepal | last post by:
Hi; I'm doing an example program from a book regarding .NET Remoting. Both the Client and Server are C# Console Applications. Server Code is using System; using System.Runtime.Remoting;...
0
by: pavan | last post by:
hi, Please refer this article because that is the dll iam using for compression/decompression of datatables. http://www.eggheadcafe.com/articles/20031219.asp This is a windows application in C#...
8
by: sandy82 | last post by:
I coded a simple example in c# In which their is a client and a server using a dll . I am confused on the Point that u have to use the .dll on both sides .Cant we have a solution of having a dll...
0
by: Phill W. | last post by:
Can VB2005 /correctly/ pass a class derived from Datatable via .Net Remoting? Using VB2003, I created a class inherited from DataTable and added some extra bits to it. All was well until I...
1
by: Tommaso Caldarola | last post by:
I need to transfer big files (up to 10 Gb), now I'm using IIS via Remoting with chunk of bytes (up to 500Kb). In the following article: Middle-Tier Hosting: Enterprise Services, IIS, DCOM, Web...
13
by: José Joye | last post by:
Hello, What is the best way to stop a remoting server (Singleton SAO) that has been started with RemotingConfiguration.Configure(). For sure, I want to do this without quitting the application...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.