Is there a way for an Inno Setup script to include code that creates custom pages AND an external .isi file (I'm using the ISSI add-in.) If I try to use both, I get the error message that says "Duplicate Identifier: INITIALIZEWIZARD" because (obviously) the identifier occurs both in my main script and in the add-in.
Here (incomplete!) is the code I want to use to create a custom page (I've taken it almost entirely from the examples supplied with Inno Setup:
procedure CreateTheWizardPages;
var
Page: TWizardPage;
RichEditViewer: TRichEditViewer;
vDosFolder: String;
begin
if RegQueryStringValue(HKEY_CURRENT_USER, 'Software\WPDOS.org','vDosDir', vDosFolder) then
begin
if ((DirExists(vDosFolder + '\62Config')) OR (DirExists(vDosFolder + '\61Config')) OR (DirExists(vDosFolder + '\51Config'))) then
begin
Page := CreateCustomPage(wpInfoBefore, 'Existing installation found', 'Read this message!');
RichEditViewer := TRichEditViewer.Create(Page);
RichEditViewer.Width := Page.SurfaceWidth;
RichEditViewer.Height := Page.SurfaceHeight;
RichEditViewer.Parent := Page.Surface;
RichEditViewer.ScrollBars := ssVertical;
RichEditViewer.UseRichEdit := True;
RichEditViewer.RTFText := '{\rtf1\ansi\ansicpg1252\deff0\deflang1043{\fonttbl{\f0\fswiss\fcharset0 Arial;}}{\colortbl ;\red255\green0\blue0;\red0\green128\blue0;\red0\green0\blue128;}\viewkind4\uc1\pard\f0\fs20 R\cf1 ead\cf2 This\cf3 Message!\cf0\par}';
RichEditViewer.ReadOnly := True;
end;
end;
end;
procedure InitializeWizard();
begin
CreateTheWizardPages;
end;
What I also want to do (if possible) is us the ISSI addin to put a clickable link on status bar of the wizard, but if I include this code I get the error message:
[ISSI]
#define ISSI_English
#define ISSI_URL
#define ISSI_URLText
#define ISSI_IncludePath "X:\ISSI"
#include ISSI_IncludePath+"\_issi.isi"
Plus, of course, some lines in Custom Messages spelling out what ISSI is supposed to display.
If there's any way to have both these things, I'll be grateful to hear it.