Excel to XML

Can any body plz post codes to generate Xml from a excel spreadsheet
the xml shud generate for each row of the spreadsheet
that is there is a excel sheet....with lots of rows(random) &
columns(random)
now i have to generate xml for each row
thanx

Ooh, a mystery. You've given us a clue as to what your problem is,
without giving away the whole thing. Mind if I play along? I'll give
you an answer, and then maybe you can provide more clues as to what
you're looking for. Fun stuff.

From Excel 2007: File -> Save As -> XML Spreadsheet (2003)

You can also try using the FasterCSV library to convert it to xml

there are two gems at rubyforge which can read excel-files:

‘parseexcel’ and ‘roo’.

Depending on your needs all you have to do is outputting an xml-document.

-Thomas

Thomas Preymesser wrote:

Mark Thomas wrote:

Can any body plz post codes to generate Xml from a excel spreadsheet
the xml shud generate for each row of the spreadsheet
that is there is a excel sheet....with lots of rows(random) &
columns(random)
now i have to generate xml for each row
thanx

Ooh, a mystery. You've given us a clue as to what your problem is,
without giving away the whole thing. Mind if I play along? I'll give
you an answer, and then maybe you can provide more clues as to what
you're looking for. Fun stuff.

From Excel 2007: File -> Save As -> XML Spreadsheet (2003)

i know the above way but my office 2007 is not supporting this.....
error mapping is showing that no xml mapping is in my spread sheet....
and i want ruby code for that.................
i am using parse excel.................
& i am very new in ruby............
i am using ruby 128-26
& MS-OFFICE 2007 is in my machine
so plz if post some usefull code with details.........

Mark Mr wrote:

You can also try using the FasterCSV library to convert it to xml

how can i do that......... will u plz inform me in details

now i am using parse excel.................
& i am very new in ruby............
i am using ruby 128-26
& MS-OFFICE 2007 is in my machine
so plz if post some usefull code with details.........

Mark Thomas wrote:
>> Can any body plz post codes to generate Xml from a excel spreadsheet
>> the xml shud generate for each row of the spreadsheet
>> that is there is a excel sheet....with lots of rows(random) &
>> columns(random)
>> now i have to generate xml for each row
>> thanx

> Ooh, a mystery. You've given us a clue as to what your problem is,
> without giving away the whole thing. Mind if I play along? I'll give
> you an answer, and then maybe you can provide more clues as to what
> you're looking for. Fun stuff.

> From Excel 2007: File -> Save As -> XML Spreadsheet (2003)

i know the above way but my office 2007 is not supporting this.....
error mapping is showing that no xml mapping is in my spread sheet....

Yes, it does. Your actions may look more like the following:

Office Logo button -> Save As -> Other Formats. Choose 'XML
Spreadsheet 2003 (*.xml)' from the Save As Type drop-down.

and i want ruby code for that.................

OK, fair enough. But since this is a Rails forum, your question would
have been better in comp.lang.ruby.

i am using parse excel.................

Are you USING it? Like, you've installed it, read through the APIs and
online tutorials enough to try something? If so, then post a code
snippet (preferably to comp.lang.ruby) along with what you want it to
do, and people will be happy to help.

& i am very new in ruby............
i am using ruby 128-26
& MS-OFFICE 2007 is in my machine

So you are using Windows with Excel installed. You also have the
option of automating excel with Win32-OLE. See
http://rubyonwindows.blogspot.com/search/label/excel for details.

so plz if post some usefull code with details.........

Code samples can be found with web searches. If you can show that
you've at least TRIED to solve this problem on your own, by providing
some of your own code, working or not, people are more likely to help.

- Mark.