I am using the following code to set directory path after clicking Browse button.
Function ExternalFolderBrowseClick
# Browse button clicked
# Get current folder to set as default
${NSD_GetText} $ExternalPage.Folder $ExternalPage.Folder_Text
# Browse for new folder
nsDialogs::SelectFolderDialog /NOUNLOAD "" $ExternalPage.Folder_Text
Pop $ExternalPage.Folder_Text
${NSD_SetText} $ExternalPage.Folder $ExternalPage.Folder_Text
FunctionEnd
But while compiling I am getting error in ${NSD_SetText}.
It is saying Invalid Command.
What should I do in this case
Error in ${NSD_SetText}
4 posts
I had the same problem and used SendMessage instead of SetText
SendMessage $ExternalPage.Folder ${WM_SETTEXT} 1 "STR:$ExternalPage.Folder_Text"
SendMessage $ExternalPage.Folder ${WM_SETTEXT} 1 "STR:$ExternalPage.Folder_Text"
1, where the hell did you get 1 from, wParam is not used, better to set it to 0
I was getting the error. The command is only implemented in 2.36 it seems. Get that version of NSIS and it should work.