1

Please find below function which gets called before start installation process.

I want have function to create system restore point before start installation process.

Now whats my functionality works perfect, but the UI gets freeze.

i want to show marquee progress and UI should be resposive but after reading lots of article, i am unable to find any useful.

function PrepareToInstall(var NeedsRestart: Boolean): String;
var
  WasVisible: Boolean;
begin
    // show the PreparingLabel
    WizardForm.PreparingLabel.Visible := True;

    WizardForm.ProgressGauge.Style := npbstMarquee;

    // set a label caption
    WizardForm.PreparingLabel.Text := 'Creating system Restore Point...';

    CreateSystemRestorePoint();

     WizardForm.ProgressGauge.Style := npbstNormal;

end;

Please help me on this, you answer can help me a lot.

Many Thanks.

Ramkrushna
  • 36
  • 3
  • Why this code reminds me of pascal, rather than C++? If you want to do some heavy work, while keeping UI responsive - do all of that heavy work in a separate thread. – Algirdas Preidžius Mar 09 '17 at 10:38
  • Possible duplicate of [Innosetup: how to modify long running script so it will not freeze GUI?](http://stackoverflow.com/questions/14385393/innosetup-how-to-modify-long-running-script-so-it-will-not-freeze-gui) – Steeve Mar 09 '17 at 10:42

0 Answers0