Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Inno Setup - How to localize a string in Pascal Script?

How to change the 'Next' with a language? It is possible?

procedure CurPageChanged(CurPageID: Integer);
begin
  if CurPageID = iscustompage1.id then
    starttimer(WizardForm.Handle,WizardForm.NEXTBUTTON.Handle,'Next',5)
  else
  if (CurPageID = wpWelcome) or (CurPageID = wpSelectDir) then
  begin
    stoptimer();
  end;
end;
like image 733
Nico Z Avatar asked Mar 26 '26 20:03

Nico Z


1 Answers

To localize a string for Pascal Script, define a custom message in the language file:

[CustomMessages]
NextButtonCaption=Next

And then use this custom message using the CustomMessage function function in your code:

starttimer(
  WizardForm.Handle, WizardForm.NEXTBUTTON.Handle, 
  CustomMessage('NextButtonCaption'), 5)
like image 78
Martin Prikryl Avatar answered Mar 29 '26 09:03

Martin Prikryl



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!