3

Im using ISSI plugin for Inno Setup and i am getting a error trying to use a ISSI function in my [CODE] section

Uknown identifier 'ISSI_CurPageChanged'   

The plugin is free and it´s main functions are available at: http://members.home.nl/albartus/inno/ISSI_Functions/ISSI_Functions_Overview.htm

http://members.home.nl/albartus/inno/General_Information/Download_ISSI.htm

I have to use this ISSI function because otherwise i get a duplicate error trying to use CurPageChanged.

My code is the follow:

#define ISSI_WizardBitmapImage2 "EcraFinal.bmp"
#define ISSI_WizardBitmapImage2_x 495
#define ISSI_WizardBitmapImage2_Align

#define ISSI_UseMyCurPageChanged
#define ISSI_BeveledLabel ""

#define ISSI_WizardBitmapImage "EcraInicial.bmp"
#define ISSI_WizardBitmapImage_x 495
#define ISSI_WizardBitmapImage_Align

; Include Plugin ISSI 
#define ISSI_IncludePath "C:\ISSI"
#include ISSI_IncludePath+"\_issi.isi"

[Setup]
...

[Run]
...

[Code]
procedure ISSI_CurPageChanged(CurPageID: Integer);

begin
if CurPageID = wpWelcome then 
begin
WizardForm.NextButton.Caption := SetupMessage(msgButtonInstall);  
//or := 'YourNewNextButtonText' or := ExpandConstant('{cm:YourCmTitleForNext}')
WizardForm.CancelButton.Caption := ExpandConstant('{cm:Cancelar isto}');
end; //begin + end to make changes only for this single page
end;
[/Code]

The _issi-isi file exists and is being correctly addressed by my app. Any sugestions for what it might be? Thank you in advance.

Martin Prikryl
  • 188,800
  • 56
  • 490
  • 992
Andre Garcia
  • 894
  • 11
  • 30
  • The solution by using `ISSI_`-prefixed event function is now obsolete in Inno Setup 6, with its event attributes. See [Merging event function (InitializeWizard) implementations from different sources](https://stackoverflow.com/q/40512631/850848). Also see [Implementing event functions InitializeWizard while using ISSI in Inno Setup: Duplicate identifier 'INITIALIZEWIZARD'](https://stackoverflow.com/q/53423064/850848) – Martin Prikryl Mar 31 '20 at 11:11

1 Answers1

2

Its a begginer mistake! :)

If you ever face this error, remember to include the ISSI Plugin (the _issi.isi file) after your [Code] section. Like this:

#define ISSI_WizardBitmapImage "EcraInicial.bmp"
#define ISSI_WizardBitmapImage_x 495
#define ISSI_WizardBitmapImage_Align

#define ISSI_WizardBitmapImage2 "EcraFinal.bmp"
#define ISSI_WizardBitmapImage2_x 495
#define ISSI_WizardBitmapImage2_Align

#define ISSI_BeveledLabel ""
#define ISSI_UseMyCurPageChanged

[Setup]
...

[Run]
... 

[Code]
procedure ISSI_CurPageChanged(CurPageID: Integer);
begin
  if CurPageID = wpWelcome then 
  begin
    WizardForm.NextButton.Caption := SetupMessage(msgButtonInstall);  
    WizardForm.CancelButton.Caption := ExpandConstant('{cm:Cancelar isto}');
  end;
end;
[/Code]

; Include Plugin ISSI
#define ISSI_IncludePath "C:\ISSI"
#include ISSI_IncludePath+"\_issi.isi"
TLama
  • 75,147
  • 17
  • 214
  • 392
Andre Garcia
  • 894
  • 11
  • 30
  • That's weird. This solution doesn't explain why would you get an error about duplicate event method identifiers. By writing it later in your script you just include that other event method later only. Nothing more. They should be still duplicated. – TLama Mar 17 '14 at 12:09
  • 1
    You´re right. If you try the procedure CurPageChanged in the [Code] section you get a duplicate event error because that function is already being used by ISSI. Like it says in http://members.home.nl/albartus/inno/ISSI_Functions/ISSI_Functions_Overview.htm (Use your custom CurPageChanged if the function is used by ISSI). I didn´t include [Setup] section to simplify things. Thanks TLama. – Andre Garcia Mar 17 '14 at 12:11
  • Shouldn't you [`use this code`](http://members.home.nl/albartus/inno/ISSI_Functions/ISSI_UseMyCurPageChanged.htm) ? I think you're missing the `ISSI_UseMyCurPageChanged` conditional define now... – TLama Mar 17 '14 at 12:15
  • And it´s being used. The 'ISSI_UseMyCurPageChanged' it´s defined in the 4th line and the structure is the same. – Andre Garcia Mar 17 '14 at 12:20
  • Ah, sorry, I missed that! I've made a small changes in your answer. Hope you don't mind :) – TLama Mar 17 '14 at 12:32
  • Dont mention. Thank you! – Andre Garcia Mar 17 '14 at 20:45