Hello All,
What i am trying to do is create a function to read out Excel.
It should accept as parameter an InFileName
And as output is should give an Output
The function needs to iterate over all the excel sheets and return all sheet information in the 'Output' variable
Underneath example is how i imagine it should work. However i get an error that the Output variable can't contain a list of datatables.
I've also tried creating Custom Objects, convert the list to JSON and try and parse back again in the calling function, but i can't seem to parse it back to the list objects it was, and thus that method also was a bit of a dead end.
Excel.LaunchExcel.LaunchAndOpenUnderExistingProcess Path: File Visible: False ReadOnly: True Instance=> ExcelInstance
Variables.CreateNewList List=> List
Excel.GetAllWorksheets Instance: ExcelInstance Worksheets=> SheetNames
LOOP FOREACH Sheet IN SheetNames
Excel.SetActiveWorksheet.ActivateWorksheetByName Instance: ExcelInstance Name: Sheet
Excel.ReadFromExcel.ReadAllCells Instance: ExcelInstance ReadAsText: False FirstLineIsHeader: True RangeValue=> ExcelData
Variables.AddItemToList Item: ExcelData List: List
END
SET NewOutput TO List
Excel.CloseExcel.Close Instance: ExcelInstance
Any IT wizard out there with great idea's?