StrataFrame Forum

Load data from excel file

http://forum.strataframe.net/Topic10716.aspx

By Chan - 8/3/2007

Hi,

How could I load data excel into BO?



Thank you
By Trent L. Taylor - 8/4/2007

Well, this is obviously not a native function of the BO, so you will need to convert the Excel document into XML and then you can use the ADO.NET DataTable command to read in the XML document and finally you can use the CopyDataFrom on the BO to bring the data in in a known format.

I recommend using the MSOffice Interop classes to open and read the Excel document and dump it into an XML format.  Once this is done you can bring it into a DataTable which can then be brought into the BO.

By Greg McGuffey - 8/6/2007

I thought there was a ADO.NET driver for excel (there was for ADO). If there is, you could just open excel via ADO.NET. As I recall the excel drivers are finicky.
By Kari Paukku - 8/6/2007

Hi,

we had the same type of problem (Excel to Oracle) and in the end decided to use a commercial tool/component from Syncfusion (http://www.syncfusion.com/products/xlsio/windows/default.aspx) together with SF in a VB.Net environment. That solution worked fine for us.

Kari