02-29-2012, 03:53 PM
(This post was last modified: 02-29-2012, 04:16 PM by simon_schreiner.)
Hey there,
I'm trying to copy some Sheets from an Excel file to DataTables. Since the Excel file is opened during the test run I can neither use nor
I'm currently creating an instance of the Excel file via
and then setting objects for the needed Excel Sheets via
...
By this I get an instance of the wanted Excel Worksheets. I can get the name and the content of cells etc.
What I'm now trying to do is to somehow copy the complete content of the xlsworksheet into my datatable. I have already thought about using loops but hope there's a better and more performant solution.
Anyone able to help me?
Thanks for your help
Simon
edit: forgot to use code tags, sry for that
I'm trying to copy some Sheets from an Excel file to DataTables. Since the Excel file is opened during the test run I can neither use
Code:
DataTable.import(path)
Code:
DataTable.ImportSheet path,source,dest
I'm currently creating an instance of the Excel file via
Code:
Set xlsworkbook = GetObject("path")
Code:
Set xlsworksheet1 = xlsworkbook.WorkSheets("name1")
Set xlsworksheet2 = xlsworkbook.WorkSheets("name2")
By this I get an instance of the wanted Excel Worksheets. I can get the name and the content of cells etc.
What I'm now trying to do is to somehow copy the complete content of the xlsworksheet into my datatable. I have already thought about using loops but hope there's a better and more performant solution.
Anyone able to help me?
Thanks for your help
Simon
edit: forgot to use code tags, sry for that