windows - How to install into CSIDL_COMMON_APPDATA -


using nsis, want set installdir csidl_common_appdata.

this might like

c:\documents , settings\all users\application data

unfortunately, the variables/constants allowed in installdir not support common app data folder.

so tried:

system::call 'shell32::shgetspecialfolderpath(i $hwndparent, t .r1, 0x23, i0)i.r0' installdir "$1\myproduct" 

(0x23 equals csidl_common_appdata)

when compiling this, nsis complains following error:

error: can't add entry, no section or function open!

my question:

how set installation directory csidl_common_appdata?

the setshellvarcontext instruction changes of nsis constants point all-users version of special path:

function .oninit setshellvarcontext strcpy $instdir $appdata functionend 

Comments

Popular posts from this blog

python - No exponential form of the z-axis in matplotlib-3D-plots -

php - Best Light server (Linux + Web server + Database) for Raspberry Pi -

c# - "Newtonsoft.Json.JsonSerializationException unable to find constructor to use for types" error when deserializing class -