Inno checkbox

Hi,

Need to put additional txt with checkbox "I confirm that blablabla" when checked only possible to make next step in install...
Anyone  know?

NoradEEAsked:
Who is Participating?
 
mirtheilConnect With a Mentor Commented:
This should do what you want:
; -- CodeDlg.iss --
;
; This script shows how to insert custom wizard pages into Setup and how to handle
; these pages. Furthermore it shows how to 'communicate' between the [Code] section
; and the regular Inno Setup sections using {code:...} constants. Finally it shows
; how to customize the settings text on the 'Ready To Install' page.

[Setup]
AppName=My Program
AppVerName=My Program version 1.5
DefaultDirName={pf}\My Program
DisableProgramGroupPage=yes
UninstallDisplayIcon={app}\MyProg.exe
OutputDir=userdocs:Inno Setup Examples Output

[Files]
Source: "MyProg.exe"; DestDir: "{app}"; Flags: ignoreversion

[Code]
var
Page: TWizardPage;

procedure  ChkOnChange (Sender: TObject);
var
MyCheckBox : TCHeckBox;
begin
MyCheckBox := TCheckBox(Sender);
if MyCheckBox.Checked then
  WizardForm.NextButton.Enabled := true
else
  WizardForm.NextButton.Enabled := false;
end;


procedure InitializeWizard;
var
  CheckBox: TCheckBox;
begin
  Page := CreateCustomPage(wpWelcome, 'Custom wizard page controls', 'TCheckBox example');

  CheckBox := TCheckBox.Create(Page);
  CheckBox.Width := Page.SurfaceWidth;
  CheckBox.Height := ScaleY(17);
  CheckBox.Caption := 'TCheckBox';
  CheckBox.Checked := False;
  CheckBox.Parent := Page.Surface;
  CheckBox.OnClick := @ChkOnChange;

end;

procedure CurPageChanged(CurPageID: Integer);
begin
if CurPageId = Page.ID then
  WizardForm.NextButton.Enabled := false;
end;

end.

Open in new window

0
 
NoradEEAuthor Commented:
for clarify: similar has avira av personal while installing asking for comnifrmation about non commercial use...
0
 
mirtheilCommented:
Are you trying to have a license dialog displayed so that the user must accept it?  
If so, add the LicenseFile= to your [Setup] section.  You'd need to point it to a Text or RTF file.  
Something like:

; Script generated by the Inno Setup Script Wizard.
; SEE THE DOCUMENTATION FOR DETAILS ON CREATING INNO SETUP SCRIPT FILES!

#define MyAppName "My Program"
#define MyAppVerName "My Program 1.5"
#define MyAppPublisher "My Company, Inc."
#define MyAppURL "http://www.example.com/"
#define MyAppExeName "MyProg.exe"

[Setup]
AppName={#MyAppName}
AppVerName={#MyAppVerName}
AppPublisher={#MyAppPublisher}
AppPublisherURL={#MyAppURL}
AppSupportURL={#MyAppURL}
AppUpdatesURL={#MyAppURL}
DefaultDirName={pf}\{#MyAppName}
DefaultGroupName={#MyAppName}
OutputBaseFilename=setup
Compression=lzma
LicenseFile=readme.txt
SolidCompression=yes

[Languages]
Name: "english"; MessagesFile: "compiler:Default.isl"

[Tasks]
Name: "desktopicon"; Description: "{cm:CreateDesktopIcon}"; GroupDescription: "{cm:AdditionalIcons}"; Flags: unchecked

[Files]
Source: "MyProg.exe"; DestDir: "{app}"; Flags: ignoreversion
; NOTE: Don't use "Flags: ignoreversion" on any shared system files

[Icons]
Name: "{group}\{#MyAppName}"; Filename: "{app}\{#MyAppExeName}"
Name: "{commondesktop}\{#MyAppName}"; Filename: "{app}\{#MyAppExeName}"; Tasks: desktopicon

[Run]
Filename: "{app}\{#MyAppExeName}"; Description: "{cm:LaunchProgram,{#MyAppName}}"; Flags: nowait postinstall skipifsilent

Open in new window

0
Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

 
NoradEEAuthor Commented:
> Are you trying to have a license dialog displayed so that the user must accept it?  
no look at my second additional comment after post
0
 
mirtheilCommented:
So you want two agreements?  One for the license and the second for some other confirmation?  
0
 
NoradEEAuthor Commented:
See this:
http://img528.imageshack.us/i/94008901.jpg/

Need similar, one agreement already exist this is std and easy, as last step before proceed to install final confirmation in such style in inno...
0
 
NoradEEAuthor Commented:
is that possible in inno?
0
 
NoradEEAuthor Commented:
There is a problem with lenght of: CheckBox Caption 'TCheckBox'

Seems to be limited to width of installer window and not word wrapping to next line if caption is longer.

Any solution for that?

0
All Courses

From novice to tech pro — start learning today.