MATLAB Function Reference Previous page   Next Page
winqueryreg

Get item from Microsoft Windows registry

Syntax

Description

value = winqueryreg('name', 'rootkey', 'subkey') returns the key names in rootkey\subkey in a cell array of strings. The first argument is the literal quoted string, 'name'.

If the value retrieved from the registry is a string, winqueryreg returns a string. If the value is a 32-bit integer, winqueryreg returns the value as an integer of MATLAB type int32.

value = winqueryreg('rootkey', 'subkey', 'valname') returns the value for key valname in rootkey\subkey.

value = winqueryreg('rootkey', 'subkey') returns a value in rootkey\subkey that has no value name property.

Remarks

This function works only for the following registry value types:

Examples

Example 1

Get the value of CLSID for the MATLAB sample COM control mwsampctrl.2:

Example 2

Get a list in variable mousechar for registry subkey Mouse, which is under subkey Control Panel, which is under root key HKEY_CURRENT_USER.

For each name in the mousechar list, get its value from the registry and then display the name and its value:


Previous page  winopen wk1finfo Next page

© 1994-2005 The MathWorks, Inc.