simple(?) xml/xsl problem with xml from sql query

D

dSchwartz

I'm creating xml files from a dataset:
myDataSet.WriteXml(m_XmlFile, XmlWriteMode.IgnoreSchema);

and saving them to disk. Then i want to use the Xml control to format
this xml with xsl stylesheet. here is part of my xml file created by
the line above:

<?xml version="1.0" standalone="yes" ?>
<NewDataSet>
<articles>
<XML_F52E2B61-18A1-11d1-B105-0080F4...>
<sm_articles article_id="2" article_title="xxxx" ... />
<sm_articles article_id="3" article_title="yyyy" ... />
</XML_F52E.......>
</articles>
</NewDataSet>

Now in my xslt i can do a for-each select="//articles" and it will
give me one item, but i'm not able to get past the <XML_.... tag. If
i try select="//sm_articles" i don't get errors, like its returning an
empty node.

so my question is what is the <XML_.... tag all about and how do i get
past it? If i manually take that tag out then my Xml control works
fine with my xsl stylesheet, but i have to build these xml files on
the fly from sql server.

Thanks for your time!
 
B

Bryant Likes

dSchwartz said:
I'm creating xml files from a dataset:
myDataSet.WriteXml(m_XmlFile, XmlWriteMode.IgnoreSchema);

Where are you getting the XML in the DataSet from? That looks like the
column header that is returned when you run a FOR XML Query.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Members online

Forum statistics

Threads
473,769
Messages
2,569,580
Members
45,054
Latest member
TrimKetoBoost

Latest Threads

Top