I'm experienceing a new and strange problem with a WebMethod I am working
on. It creates an instance of a class which contains a number of fields,
Collections, and classes, all of which are serializable (I'm pretty sure).
It compiles fine, and when I run it, I can step through all of the code I
wrote without exception, but it returns the following message:
"There was an error generating the XML document. --> index is outside the
bounds of this Collection"
Anyone have a clue as to where to find the answer to this? I haven't been
able to Google a thing.
--
Thanks,
Kevin Spencer
..Net Developer
Microsoft MVP
I get paid good money to
solve puzzles for a livingDoes this error happen only through code or does it happen if you hit the
ASMX through an application like Web Service Studio (or the local test
page)? If it only happens in code, The place to look would be the
reference.vb file.
You don't have to use the generated classes in the reference.vb, you can
erase them and add whatever imports are neccesary to make it use your
original classes. This might be a good troubleshooting step.
"Kevin Spencer" <kspencer@.takempis.com> wrote in
news:#kAQxftuEHA.1524@.TK2MSFTNGP09.phx.gbl:
> Hi All,
> I'm experienceing a new and strange problem with a WebMethod I am
> working on. It creates an instance of a class which contains a number
> of fields, Collections, and classes, all of which are serializable
> (I'm pretty sure). It compiles fine, and when I run it, I can step
> through all of the code I wrote without exception, but it returns the
> following message:
> "There was an error generating the XML document. --> index is outside
> the bounds of this Collection"
> Anyone have a clue as to where to find the answer to this? I haven't
> been able to Google a thing.
Thanks,
I figured it out. There actually WAS an exception occurring, which was being
trapped. When I stepped through the code, I stepped over the method call
that raised the exception. Fortunately, I was also logging exceptions, so
when I went into the log I found the exception and the source of it.
--
HTH,
Kevin Spencer
..Net Developer
Microsoft MVP
I get paid good money to
solve puzzles for a living
"cbDevelopment" <development@.remove.700cb.net> wrote in message
news:Xns958FD359943E9cbDevelopment@.207.46.248.16.. .
> Does this error happen only through code or does it happen if you hit the
> ASMX through an application like Web Service Studio (or the local test
> page)? If it only happens in code, The place to look would be the
> reference.vb file.
> You don't have to use the generated classes in the reference.vb, you can
> erase them and add whatever imports are neccesary to make it use your
> original classes. This might be a good troubleshooting step.
>
> "Kevin Spencer" <kspencer@.takempis.com> wrote in
> news:#kAQxftuEHA.1524@.TK2MSFTNGP09.phx.gbl:
> > Hi All,
> > I'm experienceing a new and strange problem with a WebMethod I am
> > working on. It creates an instance of a class which contains a number
> > of fields, Collections, and classes, all of which are serializable
> > (I'm pretty sure). It compiles fine, and when I run it, I can step
> > through all of the code I wrote without exception, but it returns the
> > following message:
> > "There was an error generating the XML document. --> index is outside
> > the bounds of this Collection"
> > Anyone have a clue as to where to find the answer to this? I haven't
> > been able to Google a thing.
0 comments:
Post a Comment