cfregistry action = "getAll"

Description

Used with the getAll action to return all registry keys and values defined in a branch. You can access the values as you would any record set.

Category

Variable manipulation tags

Syntax

<cfregistry action = "getAll"
  branch = "branch"
  type = "data type"
  name = "query name" 
  sort = "criteria"> 

See also

cfcookie, cfparam, cfsavecontent, cfschedule, cfset

Attributes

Attribute
Description
branch
Required. The name of the registry branch that contains the keys or values to access.
type
Optional. The type of data to access:
  • string    Return string values (default)
  • dWord    Return DWord values
  • key    Return keys
  • any    Return keys and values
name
Required. The name of the record set to contain returned keys and values.
sort
Optional. Sorts query column data (case-insensitive). Sorts on Entry, Type, and Value columns as text. Specify any combination of columns from query output in a comma-separated list. ASC (ascending) or DESC (descending) can be specified as qualifiers for column names. ASC is the default. For example:
sort = "value DESC, entry ASC" 

Usage

cfregistry returns #entry#, #type#, and #value# in a record set that you can access through tags such as cfoutput. To fully qualify these variables use the record set name, as specified in the name attribute.

If #type# is a key, #value# is an empty string.

If you specify Any for type, getAll also returns binary registry values. For binary values, the #type# variable contains UNSUPPORTED and #value# is blank.

Example

<!--- This example uses cfregistry with the getAll Action --->

<html>
<head>
<title>cfregistry action = "getAll"</title>
</head>
<body>
<cfregistry action = "getAll"
 branch = "HKEY_LOCAL_MACHINE\Software\Microsoft\Java VM" 
 type = "Any" name = "RegQuery">
<P>
<H1>cfregistry action = "getAll"</H1>
<cftable query = "RegQuery" colHeaders HTMLTable border = "Yes">
<cfcol header = "<B>Entry</b>" width = "35" text = "#RegQuery.Entry#">
<cfcol header = "<B>Type</b>" width = "10" text = "#RegQuery.type#">
<cfcol header = "<B>Value</b>" width = "35" text = "#RegQuery.Value#">
</cftable>
</body>
</html>