I testing XLSRW v.5 in our application (before buying upgrade from v.4).
Please help me. How rewrite this code in version 5
v4 - worked
Code: Select all
procedure RepairLockList;
var
K: Integer;
begin
with xlsReadWrite do
for K:= 0 to Sheets.Count - 1 do
Sheets[K].SheetProtection:= DefaultSheetProtections;
end;
procedure RepairUnLockList;
var
K: Integer;
begin
with xlsReadWrite do
for K:= 0 to Sheets.Count - 1 do
if Sheets[K]._Int_Records.PROTECT = 0 then
Sheets[K].SheetProtection:= DefaultSheetProtections;
end;
- DefaultSheetProtections ?
- _Int_Records.PROTECT ?
Code: Select all
procedure RepairLockList;
var
K: Integer;
begin
with xlsReadWrite do
for K:= 0 to Count - 1 do
Sheets[K].Protection:= ?DefaultSheetProtections?;
end;
procedure RepairUnLockList;
var
K: Integer;
begin
with xlsReadWrite do
for K:= 0 to Count - 1 do
if Sheets[K].?_Int_Records.PROTECT? = 0 then
Sheets[K].Protection:= ?DefaultSheetProtections?
end;