473,508 Members | 2,267 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Serilization of custom object

Hello, I've been trying to serialize a custom object for transfer to a
web services and I'm running into a lot of problems. First of all, I'm
wanting to serialize the entire object, both private and public
properties. It seems as though when I try to accomplish this using the
XmlSerializer object, BinaryFormatter object, or the SoapFormatter
object, it will only do the public properties and methods. Is there
another object that will do what I'm wanting and I'm just missing it?
Also, I'd like to serialize this to memory and then just invoke the
method of the web service. It seems as though when using the
SoapFormatter and BinaryFormatter, I have to use a sttream object and
eventually put the data from memory to a byte array. This is
problematic because to transfer this byte array to my web service, I'd
have to loop through the array assigning the elements of the array to a
string var and then use this string var as the paramater to the web
service and parse it on the other side. This seems convulated and there
has to be another way of doing this. If anyone has any input and would
be willingto work on this with me, please let me know.

Thanks
squiggie

Mar 30 '06 #1
7 1133
<Sq*****@gmail.com> wrote in message
news:11**********************@v46g2000cwv.googlegr oups.com...
Hello, I've been trying to serialize a custom object for transfer to a
web services and I'm running into a lot of problems. First of all


First of all, what language are you using. If anything.Net, see below....

You'll want to post that question in a .Net group.
They all contain "dotnet" or "vsnet" in their names.
This and all other groups on the MS server that start with
"microsoft.public.vb"
are for VB Classic (mostly VB5/6) and were in existance long before any .Net
products were released. While some of the code looks the same, they are very
different products and require a different set of groups.

Try one of these:
news://news.microsoft.com/microsoft....dotnet.general
news://news.microsoft.com/microsoft....t.languages.vb
news://news.microsoft.com/microsoft....es.vb.controls
news://news.microsoft.com/microsoft....mework.interop
--
Ken Halter - MS-MVP-VB - Please keep all discussions in the groups..
DLL Hell problems? Try ComGuard - http://www.vbsight.com/ComGuard.htm
Mar 30 '06 #2
what are you talking about? This is a dotnet group?

Mar 30 '06 #3
On 2006-03-30, squiggie <Sq*****@gmail.com> wrote:
what are you talking about? This is a dotnet group?


best of all, such a crossposting should be avoided.

--
ciao, hal
Mar 30 '06 #4
"squiggie" <Sq*****@gmail.com> wrote in message
news:11**********************@g10g2000cwb.googlegr oups.com...
what are you talking about? This is a dotnet group?


Here's the crosspost list.

microsoft.public.dotnet.languages.vb,microsoft.pub lic.vb.general.discussion,it.comp.lang.visual-basic

Of those, only one is appropriate for dotNet related questions (afaik). No
group that starts with "microsoft.public.vb" has anything to do with dotNet.
I have no idea what version of VB "it.comp.lang.visual-basic" supports.

--
Ken Halter - MS-MVP-VB - Please keep all discussions in the groups..
DLL Hell problems? Try ComGuard - http://www.vbsight.com/ComGuard.htm
Mar 30 '06 #5
I see, my apologies. Thanks for the heads up.

Mar 30 '06 #6
"Ken Halter" ha scritto nel messaggio
I have no idea what version of VB "it.comp.lang.visual-basic" supports.


This is an IT.alian ;-) VB group. Historically "classic-VB" oriented, but
since there isn't a .NET localized NG, we accept either "style" question;
preferably with the correct tag in the subject or at least in the body.

Alas, italian language only :-).

Bye, G.
Mar 30 '06 #7
Scuigge,

Can you try this first.

http://www.vb-tips.com/default.aspx?...c-61641f5c8d9d

I am not sure anymore if you can use it in the webservice, but I thought it
would.

For those who wants this in Italian.
http://www.vb-tips.com/default.aspx?...c-61641f5c8d9d

:-))

As well replied in the newsgroups from VB from the previous millennium, to
show how easy the VB from this millennium is.

:-))

I hope this helps,

:-)

Cor

<Sq*****@gmail.com> schreef in bericht
news:11**********************@v46g2000cwv.googlegr oups.com...
Hello, I've been trying to serialize a custom object for transfer to a
web services and I'm running into a lot of problems. First of all, I'm
wanting to serialize the entire object, both private and public
properties. It seems as though when I try to accomplish this using the
XmlSerializer object, BinaryFormatter object, or the SoapFormatter
object, it will only do the public properties and methods. Is there
another object that will do what I'm wanting and I'm just missing it?
Also, I'd like to serialize this to memory and then just invoke the
method of the web service. It seems as though when using the
SoapFormatter and BinaryFormatter, I have to use a sttream object and
eventually put the data from memory to a byte array. This is
problematic because to transfer this byte array to my web service, I'd
have to loop through the array assigning the elements of the array to a
string var and then use this string var as the paramater to the web
service and parse it on the other side. This seems convulated and there
has to be another way of doing this. If anyone has any input and would
be willingto work on this with me, please let me know.

Thanks
squiggie

Mar 31 '06 #8

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

Similar topics

6
2815
by: amethyste | last post by:
hello, This is my sample (simplified): public class Binom { public string _Value;
1
1210
by: mortb | last post by:
I have a class that I want to serialize to into the viewstate of an aspx form. I've specified the attribute on top of the class definition, compiled but when I browse the page I get an excepiton...
3
4349
by: Stephan Schlicker | last post by:
Hi everyone I have a serious problem with the serilization of an user-defined object in C#. I would like to serialize an object of class D which inherits from class C. Class C as well as class D...
6
3242
by: Scott Zabolotzky | last post by:
I'm trying to pass a custom object back and forth between forms. This custom object is pulled into the app using an external reference to an assembly DLL that was given to me by a co-worker. A...
2
2564
by: Suzanne | last post by:
Hi all, I'm reposting this message as I'm experiencing this problem more and more frequently : I really hope someone out there can help me as I've been tearing my hair out on this one for a...
0
1738
by: porter_wss | last post by:
I am a bit confused on serializing objects and inherited objects. What I am trying to accomplish is creating a base object and an inherited object with additional properties. The sender of these...
3
5973
by: RJA | last post by:
Hiyas, Using VS .net 2003. Setting up a Webservice that accepts 3rd party vendor designed XML requests and returns a filled XMLDocument with response data. Vendor XSDs were serialize into...
9
3771
by: Greger | last post by:
Hi, I am building an architecture that passes my custom objects to and from webservices. (Our internal architecture requires me to use webservices to any suggestion to use other remoting...
7
1927
by: Mike9900 | last post by:
If you do .NET Remoting and Binary Serilization with DataSet it does not work. If you set the Serialization type to Binary on DataSet, it does not seralize it correctly on windows xp. To do this...
0
7224
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
7120
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
7323
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
7380
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...
1
7039
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
7494
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
4706
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
3180
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
415
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

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.