Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / .NET Framework / New Users / January 2008

Tip: Looking for answers? Try searching our database.

Remoting and DataTypes

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
-Steve- - 19 Jan 2008 19:17 GMT
I'm dealing with remoting for the first time (.net 2.0).  I can succesfully
call methods that return basic data types (string, bool, etc) but I can't
pass more complicated data types (System.DirectoryServices.DirectoryEntry is
specifically what I want to have returned).  Am I just out of luck or is
there something I can do to return that data type?
Family Tree Mike - 19 Jan 2008 20:51 GMT
It's been a while since I have used remoting, but, I believe the classes used
in the call need to be serialized.  DirectoryEntry does not implement
ISerializable, so it therefore fails.  I did send some pretty complex classes
so complexity is not the problem.

I'm not sure I would see a reason to send local directory entries via
remoting.  Perhaps you should create a utility class that carries the
necessary information from the DirectoryEntry class.

> I'm dealing with remoting for the first time (.net 2.0).  I can succesfully
> call methods that return basic data types (string, bool, etc) but I can't
> pass more complicated data types (System.DirectoryServices.DirectoryEntry is
> specifically what I want to have returned).  Am I just out of luck or is
> there something I can do to return that data type?
Amar - 26 Jan 2008 03:12 GMT
> It's been a while since I have used remoting, but, I believe the classes used
> in the call need to be serialized.  DirectoryEntry does not implement
[quoted text clipped - 10 lines]
> > specifically what I want to have returned).  Am I just out of luck or is
> > there something I can do to return that data type?

While remoting, the data passed is serialized into a bytestream and
then passed.
As a result every datatype that you want to pass should be
serializable . Since Directory entry is not serializble you need to
create a custom class with necessary information and then pass it

Rate this thread:







Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.