Skip to content

How to convert a VB array to an xml file?

I am writing a program in Visual Basic in which some calculations are made and saved into a two dimensional array. After each time I run the program I would like to save this array as an xml file (or any other format) so that I can later open it in Excel. What should I do to convert the array into an xml file?

2 Comments

  1. AnalProgrammer wrote:

    Write "<tagname>" data "</tagname>"

    Something like that.

    Wednesday, December 23, 2009 at 7:22 pm | Permalink
  2. Daniel B wrote:

    If you want to import the data into Excel I wouldn’t use XML, I would just use a comma seperated text file (.csv). Just output each row of data like this to a file:

    10.00,23.22,1.22,7.22

    Wednesday, December 23, 2009 at 7:22 pm | Permalink

Post a Comment

Your email is never published nor shared.