Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / .NET Framework / XML / January 2008

Tip: Looking for answers? Try searching our database.

How to pass xml inside xml to an xslt

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Anshul Bansal - 28 Jan 2008 09:11 GMT
Hi
I have an xslt. The input to the xslt is a dataset. In that dataset, in one
of the datatables' column I am stroring xml data using XmlDocument.

Now, when I transform this xslt in c# I get the following error:
"Unexpected XML declaration. The XML declaration must be the first node in
the document, and no white space characters are allowed to appear before it."

Is there a workaround to this problem?

Thanks,
Anshul Bansal
Martin Honnen - 28 Jan 2008 11:56 GMT
> I have an xslt. The input to the xslt is a dataset. In that dataset, in one
> of the datatables' column I am stroring xml data using XmlDocument.
[quoted text clipped - 4 lines]
>
> Is there a workaround to this problem?

Well the rules are strict, the XML declaration needs to be the first
thing in an XML document (besides a posssible BOM). So what you
currently construct as XML is not XML and can't be parsed successfully
with an XML parser. You need to fix the way you construct the XML. As
you have not shown us how you construct the XML it is difficult to give
concrete advice.
Please provide some details on how you construct the XML from the
DataSet. The .NET framework provides XmlDataDocument for that.

Signature

    Martin Honnen --- MVP XML
    http://JavaScript.FAQTs.com/


Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.