Page 1 of 1

CopySheet does not protect the hidden feature of columns

Posted: Thu Dec 10, 2015 9:45 am
by huseyinxy
Hello,

I want to copy one sheet to new one with existing hidden columns, but in the new sheet all columns are visible.

Code: Select all

procedure TForm.Button1Click(Sender: TObject);
var
  fn1, fn2: string;
  Excel: TXlsReadWriteII5;
begin
  fn1 := 'D:\Tests\Excel\temp1.xls';
  fn2 := 'D:\Tests\Excel\temp2.xls';

  Excel := TXLSReadWriteII5.Create(nil);
  Excel.Filename := fn1;
  Excel.Read;

  // add new sheet and copy first one
  Excel.Add;
  Excel.CopySheet(0, 1);

  Excel.SaveToFile(fn2);
  Excel.Free;
end;



Re: CopySheet does not protect the hidden feature of columns

Posted: Mon Dec 21, 2015 10:03 am
by larsa
Hello

I can't reproduce this. Do you have the latest update installed?

Re: CopySheet does not protect the hidden feature of columns

Posted: Mon Dec 21, 2015 3:05 pm
by huseyinxy
Hello,
I instatlled lastest version 5.20.66.
It can be reproduce with xls files. No problem with xlsx, soryy for this detail

Re: CopySheet does not protect the hidden feature of columns

Posted: Wed Dec 23, 2015 10:46 am
by larsa
Hello

Tested with XLS file and it works correct here. Please send me an excel file that causes the problem.

Re: CopySheet does not protect the hidden feature of columns

Posted: Thu Dec 24, 2015 6:57 am
by huseyinxy

Re: CopySheet does not protect the hidden feature of columns

Posted: Mon Dec 28, 2015 9:37 am
by larsa
Hello

Copying your file works fine. Do you have the latest update installed?