Listbox to Excel ( data type )

I’m trying to export Listbox data to Excel. It works well.
However, the data is stored as a string, so there is a problem to make the graph with the data in Excel.
When I change the data into number type, no problem to make the graph.

How can I export the listbox data to Excel with keeping the number type?

Do I have to change this code?

param.type = oleparameter.ParamTypeString

export it as an XML file (or heck even as an HTML table) make the extension “.XLS” and Excel will handle it all for you.

There are some that would say this isn’t the “correct” way. but it does work, its easy to implement, and it doesn’t care what platform creates the XML file.

At the company I work for, we use a more complex version of this method (it creates an XML file that meets Microsoft criteria for Excel 2003), allowing it to be sent to any of our clients without requiring them to be on any particular (ie. most recent) version of Excel