queryRegistry

Typefunction
DictionaryLCS
LibraryLiveCode Script
Syntax
the queryRegistry of <keyPath>
queryRegistry(<keyPath> [, <typeVariable>])
Summary

The queryRegistry function returns the value of an entry in the Windows system registry.

Introduced1.0
Changes

The typeVariable parameter was added in version 2.0. In previous versions, the type information was not available.

OSwindows
Platformsdesktop, server
Parameters
NameTypeDescription
keyPath

The keyPath parameter is the path to a registry entry.

typeVariable

Any legal variable name.

Example
queryRegistry("HKEY_CLASSES_ROOT\.rev\")
queryRegistry(winFilePath,myType)
Values
NameTypeDescription
return

The queryRegistry function returns a string.

RelatedKeyword: default, string
Function: deleteRegistry, value, binaryDecode, MCISendString
Glossary: binary file, variable, Windows, return, registry, value
Control Structure: function
Securityregistry
Description

Use the queryRegistry function to get system settings on a Windows system.

The first part of the keyPath should be one of the predefined handle values. If the keyPath ends in "\", the value returned is the default value for the key.

If you specify a typeVariable, the type of the data in the registry entry is placed in that variable.

Tip: To convert binary data you get from the registry to a string, use the binaryDecode function.

On Mac OS, OS X, and Unix systems, the queryRegistry function returns "not supported".