If xml doc has multiple namespace "xmlns", how should xslt be built in order to display the content of xml doc?

Hi Guys,

 If xml doc has multiple namespace "xmlns", how should xslt be built in order to display the content of xml doc? Thanks. The following is the example: 

<?xml version="1.0" encoding="utf-8"?>

<?xml-stylesheet type="text/xsl" href="report.xsl"?>

<Report xmlns="http://schemas.microsoft.com/sqlserver/reporting/2005/01/reportdefinition"

            xmlns:rd=http://schemas.microsoft.com/SQLServer/reporting/reportdesigner>

<BottomMargin>0.5in</BottomMargin>

<RightMargin>0.25in</RightMargin>

</Report> 

Thanks,

0
Alex
5/15/2007 8:35:24 PM
asp.net.xml-datasource 7181 articles. 0 followers. Follow

1 Replies
644 Views

Similar Articles

[PageSpeed] 32

Hi Alex,

Try this:

<xsl:stylesheet version="1.0"
  xmlns:temp="http://schemas.microsoft.com/sqlserver/reporting/2005/01/reportdefinition"
  xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
  <xsl:template match="/">
    <html>
      <body>
        <table>
          <tr>
            <td>
              <xsl:value-of select="temp:Report/temp:BottomMargin"/>
              <br/>
              <xsl:value-of select="temp:Report/temp:RightMargin"/>

            </td>
          </tr>
        </table>
      </body>
    </html>
    </xsl:template>
    </xsl:stylesheet>
 


NOTE:If you find my response contains a reference to a third party World Wide Web site, I am providing this information as a convenience to you.Microsoft does not control these sites and has not tested any software or information found on these sites; therefore,Microsoft cannot make any representations regarding the quality,safety, or suitability of any software or information found there.
__________________________________________________

Sincerely,
Young Fang
Microsoft Online Community Support

Please remember to click “Mark as Answer” on the post that helps you, and to click “Unmark as Answer” if a marked post does not actually answer your question. This can be beneficial to other community members reading the thread.
0
Young
5/18/2007 1:53:50 AM
Reply:

Similar Artilces:

"XML page cannot be displayed" added to XML Download
I'm using these lines to initiae a download of an xml file.  Response.Clear()Response.ContentType = "application/octet-stream"Response.AddHeader("Content-Disposition", _"attachment; filename=""" & varFileName & """")Response.Flush()Response.WriteFile(varFileName)   File looks fine in XML viewer just after created. But the output of the download, when viewed as XML, has the following, fully formatted http error imbedded in it:   XML page cannot be displayed Cannot view XML input using XSL style sheet. Please correct the error and then click the Refresh butto...

convert BASDA format XML to "standard" XML
hiya, Many of my recent problems have been that I have found it difficult to get my head round using XSLT on BASDA format XML.I feel that it would be easier to convert the BASDA format to "standard" XML, then do my XSLT. --BASDA snippet <rows> <row> <FIELD NAME="PRODUCT-TYPE">CAR</FIELD> <FIELD NAME="PRODUCT-DATE">01/01/2004</FIELD> </row> </rows> --what I regard as "standard" XML...easier to work with. <rows> <row> <PRODUCT-TYPE>CAR</P...

How to set tartget="_blank" in the xml doc for the adrotator ?
  Can someone tell me how to set the target="_blank" in the xml link section of the adrotator control?I am trying to only open the clicked ad's site and not close the current page.What to do?There’s my side and there’s your opinion Why does it have to be in the XML?<asp:AdRotator ID="AdRotator1" runat="server" Target="_blank" />   That's crazy.. I was so wrapped up in that dam xml document that I lost focus on the adrotator co...

bind xml doc to datagrid,how to update the changes to xml doc
when i use DataSet.writexml(filename), i want to write the DataSet to the file "filename", but the new data is add to the end of the "filename",but i want to update the file. DataSet ds = new DataSet(); ds.readxml("d:\\aa.xml"); and then i binddata the ds to DataGrid,i edit the DataGrid i want to update the file,so i use ds.writexml("d:\\aa.xml"); but the new data add to the end of aa.xml how can i update the aa.xml but not add to the end of file if anyone advise other sln ,i will very appreciated. help, thank...

How to: Include XML in an XML doc?
I have 4 web pages that are XML/XSLT pages. There is a certain spot on each of those pages that needs to be updated a lot with the same exact content. How do I "include" XML in XML? psuedo code: <heading>My heading</heading> <para> Some individual content that is unique to each page goes here. </para> <para> <include="anotherXMLdoc.xml" /> </para> The "anotherXMLdoc.xml" file would be the content that I need displayed on all 4 pages. I hope this make sense....

"Only one top level element is allowed in an XML doc"
Hi,I allready asked in another Thread, but there it was not the main question. So, again in this Thread.I created a new Org using des SampleProvisioningUI, subscribed to Mail-Hosting, added an Email-Plan, created a user, sent some Test-Messages. Everything fine until there. Then I tried to delete the user (respectively: the Mailbox) - all I get (using provtest) is <response>  <errorContext description="Only one top level element is allowed in an XML document."      code="0xc220140b"      executeSeqNo=&qu...

datawindow.import(XML!,"file.xml") syntax error
I am using Pocket PowerBuilder 1.5 build 360 from the help file I saw [ImportFile method (DataWindows)] long dwcontrol.ImportFile ( {saveastype importtype}, string filename {, long startrow {, long endrow {, long startcolumn {, long endcolumn {, long dwstartcolumn } } } } } ) This statement inserts all the data in the file D:\TMP\EMPLOYEE.CSV into dw_employee starting at the first column: dw_employee.ImportFile("D:\TMP\EMPLOYEE.CSV") This statement inserts all the data in the file D:\TMP\EMPLOYEE.XML into dw_employee starting at the first column: dw_em...

superreview granted: [Bug 219355] XML Parsing Error: undefined entity on files with Mime-Type: application/xhtml+xml, including about:, or "text/xml" : [Attachment 131594] use NS_GRE_DIR
Darin Fisher <darin@meer.net> has granted Benjamin Smedberg <bsmedberg@covad.net>'s request for superreview: Bug 219355: XML Parsing Error: undefined entity on files with Mime-Type: application/xhtml+xml, including about:, or "text/xml" http://bugzilla.mozilla.org/show_bug.cgi?id=219355 Attachment 131594: use NS_GRE_DIR http://bugzilla.mozilla.org/attachment.cgi?id=131594&action=edit ...

superreview requested: [Bug 219355] XML Parsing Error: undefined entity on files with Mime-Type: application/xhtml+xml, including about:, or "text/xml" : [Attachment 131594] use NS_GRE_DIR
Benjamin Smedberg <bsmedberg@covad.net> has asked Darin Fisher <darin@meer.net> for superreview: Bug 219355: XML Parsing Error: undefined entity on files with Mime-Type: application/xhtml+xml, including about:, or "text/xml" http://bugzilla.mozilla.org/show_bug.cgi?id=219355 Attachment 131594: use NS_GRE_DIR http://bugzilla.mozilla.org/attachment.cgi?id=131594&action=edit ...

superreview requested: [Bug 251274] Error: [Exception... "Node was not found" code: "8" nsresult: "0x80530008 (NS_ERROR_DOM_NOT_FOUND_ERR)" location: "chrome://inspector/content/inspector.xml Line:
Boris Zbarsky <bzbarsky@mit.edu> has asked neil@parkwaycc.co.uk <neil.parkwaycc.co.uk@myrealbox.com> for superreview: Bug 251274: Error: [Exception... "Node was not found" code: "8" nsresult: "0x80530008 (NS_ERROR_DOM_NOT_FOUND_ERR)" location: "chrome://inspector/content/inspector.xml Line: 684"] https://bugzilla.mozilla.org/show_bug.cgi?id=251274 Attachment 193251: Fix https://bugzilla.mozilla.org/attachment.cgi?id=193251&action=edit ------- Additional Comments from Boris Zbarsky <bzbarsky@mit.edu> This just makes su...

superreview requested: [Bug 211046] In <chrome://global/content/bindings/tree.xml>, "Error: this.treeBoxObject.selection has no properties" : [Attachment 146534] (Av2) <tree.xml>
Serge GAUTHERIE <gautheri@noos.fr> has asked jag (Peter Annema) <jag@tty.nl> for superreview: Bug 211046: In <chrome://global/content/bindings/tree.xml>, "Error: this.treeBoxObject.selection has no properties" http://bugzilla.mozilla.org/show_bug.cgi?id=211046 Attachment 146534: (Av2) <tree.xml> http://bugzilla.mozilla.org/attachment.cgi?id=146534&action=edit ...

superreview granted: [Bug 211046] In <chrome://global/content/bindings/tree.xml>, "Error: this.treeBoxObject.selection has no properties" : [Attachment 146534] (Av2) <tree.xml>
jag (Peter Annema) <jag@tty.nl> has granted Serge GAUTHERIE <gautheri@noos.fr>'s request for superreview: Bug 211046: In <chrome://global/content/bindings/tree.xml>, "Error: this.treeBoxObject.selection has no properties" http://bugzilla.mozilla.org/show_bug.cgi?id=211046 Attachment 146534: (Av2) <tree.xml> http://bugzilla.mozilla.org/attachment.cgi?id=146534&action=edit ------- Additional Comments from jag (Peter Annema) <jag@tty.nl> var c = this.currentIndex; - var l = this.treeBoxObject.view.rowCount - 1; + var l = this.v...

superreview granted: [Bug 211046] In <chrome://global/content/bindings/tree.xml>, "Error: this.treeBoxObject.selection has no properties" : [Attachment 147569] (Av2b) <tree.xml>
Serge GAUTHERIE <gautheri@noos.fr> has granted Serge GAUTHERIE <gautheri@noos.fr>'s request for superreview: Bug 211046: In <chrome://global/content/bindings/tree.xml>, "Error: this.treeBoxObject.selection has no properties" http://bugzilla.mozilla.org/show_bug.cgi?id=211046 Attachment 147569: (Av2b) <tree.xml> http://bugzilla.mozilla.org/attachment.cgi?id=147569&action=edit ------- Additional Comments from Serge GAUTHERIE <gautheri@noos.fr> Keeping: {{ (Av2) <tree.xml> patch 2004-04-19 15:57 PDT varga: review+ jag: super...

superreview granted: [Bug 251274] [FIX]Error: [Exception... "Node was not found" code: "8" nsresult: "0x80530008 (NS_ERROR_DOM_NOT_FOUND_ERR)" location: "chrome://inspector/content/inspector.xml Lin
neil@parkwaycc.co.uk <neil.parkwaycc.co.uk@myrealbox.com> has granted Boris Zbarsky <bzbarsky@mit.edu>'s request for superreview: Bug 251274: [FIX]Error: [Exception... "Node was not found" code: "8" nsresult: "0x80530008 (NS_ERROR_DOM_NOT_FOUND_ERR)" location: "chrome://inspector/content/inspector.xml Line: 684"] https://bugzilla.mozilla.org/show_bug.cgi?id=251274 Attachment 193251: Fix https://bugzilla.mozilla.org/attachment.cgi?id=193251&action=edit ------- Additional Comments from neil@parkwaycc.co.uk <neil.parkwa...

Web resources about - If xml doc has multiple namespace "xmlns", how should xslt be built in order to display the content of xml doc? - asp.net.xml-datasource

Resources last updated: 1/21/2016 9:20:04 PM