code porting from v4

Questions and answers on how to use XLSReadWriteII 5.
Post Reply
andrea.m86
Posts: 7
Joined: Mon Mar 04, 2013 10:56 am

code porting from v4

Post by andrea.m86 »

Hi
i've just updated my components from the previous version.
I've got some already written code that i have to make work with the new version but i have some problems with these statements:
xls.sheets.clear;
xls.sheets.add;
xls.sheets[0].rows.count;
These generate errors at compile-time (even if with the previous version everything worked fine)
how can i do these operation now?
Thanks.
Andrea
larsa
Site Admin
Posts: 926
Joined: Mon Jun 27, 2005 9:30 pm

Re: code porting from v4

Post by larsa »

Hello

Use XLS.Clear and XLS.Add instead. As there is no real Rows object, use XLS[0].LastRow to get the row count.
Lars Arvidsson, Axolot Data
andrea.m86
Posts: 7
Joined: Mon Mar 04, 2013 10:56 am

Re: code porting from v4

Post by andrea.m86 »

Thanks!
"XLS.Clear" also replace the old "XLS.sheets.clearworksheet"?
larsa
Site Admin
Posts: 926
Joined: Mon Jun 27, 2005 9:30 pm

Re: code porting from v4

Post by larsa »

Hello

No, use XLS.ClearWorkshhet
Lars Arvidsson, Axolot Data
Post Reply