OLEAutoObject
Posted: Fri Jul 21, 2023 3:15 pm
Hi to all, i have ported from VO:
oExcel := OLEAutoObject{"Excel.Application"}
it work until <<== ERROR
oExcel:Caption := cFileName
oExcel:visible := FALSE
oWorkbooks := oExcel:Workbooks
oWorkbook := oWorkbooks:Add()
oWorksheet := oWorkbook:Worksheets[1] <<== ERROR
oWorksheet:Name := "Tabella"
I got this error:
value in USUAL does not support indexed operations. The value needs to be an X# Array or implement the interface 'XSharp.IIndexedProperties'.
How is it possible to fix up and recover this code (i hope so) ? Or i have to rewrite all as C# interop ?
Thanks a lot Alessandro
oExcel := OLEAutoObject{"Excel.Application"}
it work until <<== ERROR
oExcel:Caption := cFileName
oExcel:visible := FALSE
oWorkbooks := oExcel:Workbooks
oWorkbook := oWorkbooks:Add()
oWorksheet := oWorkbook:Worksheets[1] <<== ERROR
oWorksheet:Name := "Tabella"
I got this error:
value in USUAL does not support indexed operations. The value needs to be an X# Array or implement the interface 'XSharp.IIndexedProperties'.
How is it possible to fix up and recover this code (i hope so) ? Or i have to rewrite all as C# interop ?
Thanks a lot Alessandro