Results 1 to 4 of 4

Thread: XML into Excel - leading zero

  1. #1

    XML into Excel - leading zero

    i have an XML file with both strings & numbers such as (part of the XML):

    Code:
    <CarMake>Ford</CarMake>
    <CarModel>Focus</CarModel>
    <CarYear>06</CarYear>
    Now, when taking the file and open it with Excel, it reads the CarYear as an Integer and shows just 6 instead of 06...how do I get the year to be shown as a string as well?

    Something to do with XML Schema's, but I'm not sure how this is done for just a single tag to display as a string.

    Any guidance?
    Thanks!
    "First time it's a mistake, do it again and it's stupidity."

  2. #2

  3. #3
    that would be the simple explanation for it, but this is for a client that does not want to format their excel file...they want to give it to their fleet guys and simply work with it (ur talking people with minimal knowledge of excel that need to work with the numbers and print stuff...thats it)

    and the CarYear was a sample I gave you...there is the Unit Number, Ref Num, etc. that have leading zeros. (ps - thanks for the reply though....any other ideas or suggestions?)
    "First time it's a mistake, do it again and it's stupidity."

  4. #4
    why don't you just output the excel file for them? basically make a template that has the formatting done.

    there might be something you can do with the xsd, but i'm not sure.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

Home About kirupa.com Meet the Moderators Advertise

 Link to Us

 Credits

Copyright 1999 - 2012