Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7906679
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 3, 20262026-06-03T11:04:51+00:00 2026-06-03T11:04:51+00:00

I have some XML and I need to convert them to a Microsoft Office

  • 0

I have some XML and I need to convert them to a Microsoft Office Document(2007). What’s the best and fastest way to do it? I can do it using C# or Java. I’ve seen that spire. I can do it but it’s quite expensive, is there an alternative? Does Microsoft offer something?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-03T11:04:53+00:00Added an answer on June 3, 2026 at 11:04 am

    You could use XSLT – And there’s a nice sample here on Christian Nagel’s OneNotes.

    Taking this XML

        <?xml version="1.0" encoding="utf-8" ?>
        <Courses>
         <Course Number="MS-2524">
          <Title>XML Web Services Programming</Title>
         </Course>
         <Course Number="MS-2124">
          <Title>C# Programming</Title>
         </Course>
         <Course Number="NET2">
          <Title>.NET 2.0 Early Adapter</Title>
         </Course>
        </Courses>
    

    And using this XML Style sheet:

    <?xml version="1.0" encoding="UTF-8" ?>
    <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
     xmlns:w="http://schemas.microsoft.com/office/word/2003/wordml">
     <xsl:output method="xml" indent="yes" />
     <xsl:template match="/">
      <xsl:processing-instruction name="mso-application">
       <xsl:text>progid="Word.Document"</xsl:text>
      </xsl:processing-instruction>
      <w:wordDocument>
       <w:body>
         <xsl:apply-templates select="Courses/Course" />
       </w:body>
      </w:wordDocument>
     </xsl:template>
     <xsl:template match="Course">
        <w:p>
         <w:r>
          <w:t>
           <xsl:value-of select="@Number" />, <xsl:value-of select="Title"/>
          </w:t>
         </w:r>
        </w:p>
     </xsl:template>
    </xsl:stylesheet>
    

    Can generate this MS Word Doc for 2003.

    <?xml version="1.0" encoding="utf-8"?>
    <?mso-application progid="Word.Document"?>
    <w:wordDocument xmlns:w="http://schemas.microsoft.com/office/word/2003/wordml">
      <w:body>
        <w:p>
          <w:r>
            <w:t>MS-2524, XML Web Services Programming</w:t>
          </w:r>
        </w:p>
        <w:p>
          <w:r>
            <w:t>MS-2124, C# Programming</w:t>
          </w:r>
        </w:p>
        <w:p>
          <w:r>
            <w:t>NET2, .NET 2.0 Early Adapter</w:t>
          </w:r>
        </w:p>
      </w:body>
    </w:wordDocument>
    

    To do this in code see this answer: https://stackoverflow.com/a/34095/30225

    What you need to do either use an equivalent for Office 2007 docx or just generate the 2003 doc and let people open it in 2007.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I need to Convert a CSV into an XML document. The examples I have
I have some xml documents I need to run queries on. I've created some
I have some data in a database that I need represented in an XML
I have a long document in XML from which I need to produce static
I have inherited some old code and need to convert to the latest schema
I am using PHP to generate some XML. I need to put quotes in
I'm using php to take xml files and convert them into single line tab
I need to convert some strings using Base64 encoding, and was delighted to see
I have the following code using normal Zend routing and I need to convert
I have some XML code that looks like this <SEARCHRESULTS> <FUNCTION name=BarGraph> <PARAMETER name=numList></PARAMETER>

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.