You've already forked lazarus-ccr
fpspreadsheet: Fix index bug in TsWorksheet.SetIndex (reported by forum user "iteh")
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@7012 8e941d3f-bd1b-0410-a28a-d453659cc2b4
This commit is contained in:
@ -7283,8 +7283,8 @@ begin
|
||||
if AValue < 0 then
|
||||
AValue := 0
|
||||
else
|
||||
if AValue > TsWorkbook(FWorkbook).GetWorksheetCount then
|
||||
Avalue := TsWorkbook(FWorkbook).GetWorksheetCount - 1;
|
||||
if AValue >= TsWorkbook(FWorkbook).GetWorksheetCount then
|
||||
AValue := TsWorkbook(FWorkbook).GetWorksheetCount - 1;
|
||||
oldIndex := GetIndex;
|
||||
if oldIndex <> AValue then
|
||||
TsWorkbook(FWorkbook).MoveSheet(oldIndex, Avalue);
|
||||
|
Reference in New Issue
Block a user