Skip to content
⌘ NSIS Forum Archive

Fetching Internet Explorer version

6 posts

Joke#

Fetching Internet Explorer version

Hi,

This is my first time building an installer with NSIS and I'm completely stuck at this point.
I'd like to read the IE version from the registry and i searched this forum for examples.
Now i got this:

ReadRegStr $IEVERSION HKCU "SOFTWARE\Microsoft\Windows\CurrentVersion\Internet Settings" "User Agent"

But when I want to compile i get an error on that line:

Usage: ReadRegStr $(user_var: output) rootkey subkey entry
root_key=(HKCR|HKLM|HKCU|HKU|HKCC|HKDD|HKPD)
Error in script "C:\Documents and Settings\Unknown User\Desktop\Installer\test.nsi" on line 49 -- aborting creation process

Any help how to fix?
deguix#
You forgot to define the variable $IEVERSION first. Use the "Var" command out of Sections and Functions before using the variable:

Var IEVERSION
But is recommended to use the original $1-$9, $R1-$R9 variables.