Wrox Programmer Forums
|
Pro Visual Basic 2005 For advanced Visual Basic coders working in version 2005. Beginning-level questions will be redirected to other forums, including Beginning VB 2005.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Pro Visual Basic 2005 section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old August 13th, 2008, 04:39 AM
Authorized User
 
Join Date: Jun 2008
Posts: 21
Thanks: 0
Thanked 0 Times in 0 Posts
Default Send Object

Hi,

I send XML packages to a another machine. On this moment I use a TCP listener and TCP client to do this. First I serialize my object to XML and after that I send it. The server then deserializes the object and uses it.

It seems like this takes a long time and I have problems with special characters. I also would like to have more data in one package than just the object, like a codenumber and some other parameters. Next to that it would be great if there was some error checking on the object.

I heard about SOAP and lookt for information during google sessions. It seems like that could solve my problem. But somehow the sites that are talking about it are for webdevelopers and I'm developing local software.

So basicaly my question is:
What's the best, most reliable and fastest way to send an object over the net?

Thanx in advance, koeno

 
Old August 13th, 2008, 12:50 PM
Friend of Wrox
 
Join Date: Nov 2004
Posts: 1,621
Thanks: 1
Thanked 3 Times in 3 Posts
Default

Well, the all-the-way fast way is to have the basic structure of the object at both the send and the receive location, and only send the data. At the receive end, use those data to align the local description of the object with the sate of that class of object at the sending side.

You could serialize the object to a file that both ends have access to, then retrieve that serialization at the receiving end. All you would have to send would be the location and name of the file. you could put more into that file, if you desired. or you could put more than one file, each holding a specific category of data.

Usually, if you really want speed, you have to re-invent the wheel. Processes like serialization are robust, and able to handle all contingencies, but that makes them (usually) less than optimal for any specific task.





Similar Threads
Thread Thread Starter Forum Replies Last Post
Send URL request to send sms via NowSMS deco BOOK: Professional VB 2005 ISBN: 0-7645-7536-8 0 February 16th, 2008 02:45 PM
Error on mail object .send blaabil Classic ASP Basics 6 January 16th, 2006 10:49 PM
SmartSocket question: How to send object to host magsto All Other Wrox Books 1 August 16th, 2005 02:30 PM
Send an object from a server-socket to the host? magsto General .NET 0 August 16th, 2005 06:42 AM
create a Line object ,Box object in CR at Runtime? thanhnt Pro VB 6 1 May 16th, 2005 06:51 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.