Quote:
Originally Posted by Masquerade
Maybe I am not following, but I don't see how changing the name of the Boolean for the disk adding command will fix the issue.
|
i know it's a bit confusing. but note that it's not just changing the variable name, the
ISArcExAddDisks function has also
changed.
1).
in the previous version (v0.4)
ISArcExAddDisks function returns
error state when adding the disks.
i.e. it returns
true if a disk was added
unsuccessfully (failed). so you need to catch the error state.
Code:
ISArcDiskAddingFalied:= ISArcExAddDisks(...);
if ISArcDiskAddingFalied then break;
2).
the new version (v0.4.0.1) returns the
success of adding disks.
i.e. it returns
true if a disk was added
successfully.
Code:
ISArcDiskAddingSuccess:= ISArcExAddDisks(...);
if not ISArcDiskAddingSuccess then break;
3).
this is the summarized difference.
Code:
v0.4
procedure CurStepChanged(CurStep: TSetupStep);
begin
...
ISArcDiskAddingFalied := True;
...
repeat
if FileExists(...) then
begin
ISArcDiskAddingFalied:= ISArcExAddDisks(...);
if ISArcDiskAddingFalied then break;
ISArcExDiskCount := ISArcExDiskCount + 1;
end;
...
until true;
if (not ISArcDiskAddingFalied) and ISArcExInit(...) then
begin
...
end;
end;
Code:
v0.4.0.1
procedure CurStepChanged(CurStep: TSetupStep);
begin
...
ISArcDiskAddingSuccess := False;
...
repeat
if FileExists(...) then
begin
ISArcDiskAddingSuccess:= ISArcExAddDisks(...);
if not ISArcDiskAddingSuccess then break;
ISArcExDiskCount := ISArcExDiskCount + 1;
end;
...
until true;
if (ISArcDiskAddingSuccess) and ISArcExInit(...) then
begin
...
end;
end;