MOTOBIT.COM - ASP upload, IIS utility Add Method of Keys class

Method | Member of  RegEdit.Keys | Changes | Purchase | Download

Description

Creates the specified key. If the key already exists in the registry, the method opens it.

Syntax

Set NewKey = Keys.Add (Name as String)
 

Where Type Optional Default Description
 Name  String     Name of the new key. 

Returns

Key - One registry key.

Remarks

Add Method uses RegCreateKey API function.

Examples

Add one app key and set its default value.

  'Get RegEdit.Server object
  Set S = CreateObject("RegEdit.Server")

  'Add a new key
  Set Key = S.GetKey("HKLM\SOFTWARE").CreateKey("MyFirtsApp")

  'Writes Date to the defalut key value
  Key.Values("") = Date

See also

Key.CreateKey

Other links for Add

Methods of Keys class

Add

Properties of Keys class

Count, Item

RegEdit.Keys

Collection of key objects of one registry key.

RegEdit

Intuitive, easy to use COM interface to windows registry. Set of classes to read/enumerate/modify windows registry keys and values from ASP, VBS and T-SQL.

© 1996 - 2009 Antonin Foller, Motobit Software | About, Contacts | e-mail: info@pstruh.cz