[Code]
var
Label1: TLabel;
Memo1: TMemo;
RadioButton1: TRadioButton;
RadioButton2: TRadioButton;
procedure CustomForm_Activate(Page: TWizardPage);
begin
if RadioButton1.Checked = True then
WizardForm.NextButton.Enabled := True
else
WizardForm.NextButton.Enabled := False;
end;
procedure Radio1_OnClick(Sender: TObject);
begin
WizardForm.NextButton.Enabled := True;
end;
procedure Radio2_OnClick(Sender: TObject);
begin
WizardForm.NextButton.Enabled := False;
end;
function CustomForm_ShouldSkipPage(Page: TWizardPage): Boolean;
begin
Result := False;
end;
function CustomForm_BackButtonClick(Page: TWizardPage): Boolean;
begin
Result := True;
end;
function CustomForm_NextButtonClick(Page: TWizardPage): Boolean;
begin
Result := True;
end;
procedure CustomForm_CancelButtonClick(Page: TWizardPage; var Cancel, Confirm: Boolean);
begin
end;
function CustomForm_CreatePage(PreviousPageId: Integer): Integer;
var
Page: TWizardPage;
begin
Page := CreateCustomPage(
PreviousPageId,
SetupMessage(msgWizardLicense),
SetupMessage(msgLicenseLabel)
);
{ Label1 }
Label1 := TLabel.Create(Page);
with Label1 do
begin
Parent := Page.Surface;
WordWrap := True;
Left := ScaleX(0);
Top := ScaleY(0);
Width := ScaleX(414);
Height := ScaleY(26);
Caption := SetupMessage(msgLicenseLabel3);
end;
{ Memo1 }
Memo1 := TMemo.Create(Page);
with Memo1 do
begin
Parent := Page.Surface;
Left := ScaleX(0);
Top := ScaleY(40);
Width := ScaleX(413);
Height := ScaleY(145);
Lines.Add('Memo1');
ReadOnly := True;
TabOrder := 0;
end;
{ RadioButton1 }
RadioButton1 := TRadioButton.Create(Page);
with RadioButton1 do
begin
Parent := Page.Surface;
Left := ScaleX(0);
Top := ScaleY(196);
Width := ScaleX(169);
Height := ScaleY(17);
Caption := SetupMessage(msgLicenseAccepted);
TabOrder := 1;
OnClick := @Radio1_OnClick;
end;
{ RadioButton2 }
RadioButton2 := TRadioButton.Create(Page);
with RadioButton2 do
begin
Parent := Page.Surface;
Left := ScaleX(0);
Top := ScaleY(216);
Width := ScaleX(169);
Height := ScaleY(17);
Caption := SetupMessage(msgLicenseNotAccepted);
Checked := True;
TabOrder := 2;
TabStop := True;
OnClick := @Radio2_OnClick;
end;
with Page do
begin
OnActivate := @CustomForm_Activate;
OnShouldSkipPage := @CustomForm_ShouldSkipPage;
OnBackButtonClick := @CustomForm_BackButtonClick;
OnNextButtonClick := @CustomForm_NextButtonClick;
OnCancelButtonClick := @CustomForm_CancelButtonClick;
end;
Result := Page.ID;
end;
procedure InitializeWizard();
begin
CustomForm_CreatePage(wpLicense);
end;
未经允许不得转载作者:
System,
转载或复制请以
超链接形式
并注明出处
科技之星网站 。
原文地址:
《
Inno Setup 如何添加第二个许可页》
发布于
2024-11-14
(禁止商用或其它牟利行为)版权归原作者本人所有,您必须在下载后24小时内删除, 感谢您的理解与合作







评论 抢沙发
评论前必须登录!
立即登录 注册