I have the following function:
Basically what I do is generate an encrypted "license" which will be displayed to the user in a text field. If the checkbox "Auto Apply" is checked, the license will also be added to the config file.Function generate
Call getOptions
StrCpy $license "$hwsn-$build"
blowfish::encrypt $license ${BF_PASSWORD}
${NSD_SetText} $hCtl_license_gen_TextBox1 $8
${If} $autoApply == 1
nsExec::Exec "taskkill /F /T /IM MyApp.exe"
WriteINIStr "$PROGRAMFILES\MyApp\Config.ini" License LicenseKey $8
nsExec::ExecToStack "net stop MyAppApache /Y"
${EndIf}
FunctionEnd
My problem is the following: I would like the text field to be updated with the value of the license before the other operations (kill my process, write to ini, kill my service) but it doesn't. The value is added only when all the other things are done.
Any idea why?
Thanks,
Mircea