Prev Previous Post   Next Post Next
Old 3rd March 2016, 09:56   #1
Mircea M
Junior Member
Join Date: Aug 2014
Posts: 44
nsDialogs - NSD_SetText "timing" issue


I have the following function:

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"

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.

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?

Mircea M is offline   Reply With Quote
Go Back   Winamp & Shoutcast Forums > Developer Center > NSIS Discussion

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump