Copy Sheet/Data/Cell from one file to another?

Questions and answers on how to use XLSReadWriteII 5.
Post Reply
Anonymous47
Posts: 7
Joined: Wed Jul 10, 2013 6:42 pm

Copy Sheet/Data/Cell from one file to another?

Post by Anonymous47 »

Hi,

how do i copy cells or rows from one Excel file to another, including formulas und formattings?

Excample:

var
XLS1, XLS2 : TXLSReadWriteII5;

begin
XLS1.LoadFromFile('file1.xlsx');
XLS2.LoadFromFile('file2.xlsx');

for XLS1[0].FirstRow to XLS1[0].LastRow do
begin

// how to copy the rows to XLS2[0] ?


end;

end;

Thanks.
Anonymous47
Posts: 7
Joined: Wed Jul 10, 2013 6:42 pm

Re: Copy Sheet/Data/Cell from one file to another?

Post by Anonymous47 »

No help? Bad!
larsa
Site Admin
Posts: 926
Joined: Mon Jun 27, 2005 9:30 pm

Re: Copy Sheet/Data/Cell from one file to another?

Post by larsa »

Hello

Sorry for taking some time to answer but I had a crashed computer to take care of.

It's not possible to copy between different instances of components right now. This will be added in update 5.20.07, ready by the beginning of next week. Use DestXLS.CopyCells(SrcXLS,...) or DestXLS.CopySheet(SrcXLS,...)
Lars Arvidsson, Axolot Data
Post Reply