XML TRANSFORM - Serious problem - nested element causes Index error...why oh why???
This problem is KILLING my project. I'm transforming an xml doc (step
by step instruction documents) in asp.net web form. I've tried using
the xml web control and the following code:
Private Sub Page_Load(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles MyBase.Load
'Put user code to initialize the page here
Response.Write("Hello Rod x 2")
Dim xDoc As New XmlDocument()
Dim xTrans As New XslTransform()
Dim xWriter = New XmlTextWriter(Response.Output)
xTrans.Transform(xDoc, Nothing, xWriter)
With both methods I get this error message:
Index was out of range. Must be non-negative and less than the size of
the collection. Parameter name: index
Both methods work on the EXACT same document IF I remove the third
nested level of the <step> element. xml sample structure is:
<step /> --here's where the error occurs!!!
PLEASE what am I missing? I thought one of the strengths of XML was to
be able to use this type of structure?
|All times are GMT. The time now is 05:26 AM.|
Powered by vBulletin®. Copyright ©2000 - 2013, vBulletin Solutions, Inc.
SEO by vBSEO ©2010, Crawlability, Inc.