Thanks for the response Zafar.
I *think* i have tracked it down:
I have an XmlElement in my Class:
public System.Xml.XmlElement trackingInfo;
When I would receive a null value for this:
<trackingInfo/>
The CPU would shoot to 100%. I am at a loss as to why this would happen,
but when there is content for this field, it works fine.
Reg
[quoted text, click to view] "Zafar Abbas" <someone@somewhere.com> wrote in message
news:O$tOlCF9FHA.3132@TK2MSFTNGP12.phx.gbl...
> could you post the xml/xsd data which causes this, as well as compile-able
> code which shows the problem?
>
> "Reg" <sdfsf@hostmail.com> wrote in message
> news:qYGif.643617$tl2.591177@pd7tw3no...
> > OK, Here is the issue:
> >
> > I have a string of XML that has been validated against the XSD.
> >
> > This XSD also created a class called XMLRequest (using xsd.exe).
> >
> > When I attempt the following code, my CPU is zooming to near 100%
> > (aspnet_wp) eventually the request times out.
> >
> > ---------
> > XmlSerializer xs;
> > MemoryStream memoryStream ;
> > XmlTextWriter xmlTextWriter ;
> >
> > xs = new XmlSerializer(typeof(XMLRequest));
> > memoryStream = new MemoryStream(xmlutil.StringToUTF8ByteArray(xmlfile));
> > xmlTextWriter = new XmlTextWriter(memoryStream, Encoding.UTF8);
> >
> > //CODE DIES HERE
> > XMLRequest xRequest=(XMLRequest)xs.Deserialize(memoryStream);
> > //CODE DIES HERE
> > ---------
> >
> > Any ideas what may be causing this? My XML/XSD is fairly
straigtforward,
> > only ever nests to 2 deep at the max.
> >
> > Are there certain structures or other wise I should avoid? Or perhaps a
> > better method for doing this.
> >
> > Thanks for Reading!
> >
> > Reg
> >
> >
> >
> >
> >
>
>