Skip to content

WriteUInt - cRegistry

Writes a UInteger Value into the currently open Key of the Windows Registry

Type: Procedure

Parameters

Parameter Type Description
sValue WString The name of the Value to write to. If this parameter is an empty string, then the contents of sValueData will be written to the "default" Value
uValueData UInteger The data to write

Syntax

Procedure WriteUInt WString sValue UInteger uValueData

Call Example

Send WriteUInt sValue uValueData

Description

Use WriteUInt to write a UInteger value into the currently open Key. If the value does not exist, it will be created.

Use cRegistry.pkg

Object oRegistry is a cRegistry

    Procedure DoWriteData
        UInteger uiData

        Move 5 to uiData

        // Open the Key...
        Get CreateKey "Software\MyCompany\MyProduct" to iError
        If (iError =0) Begin
            Send WriteUInt "User Count" uiData
            Send CloseKey // must close all open Keys
        End
    End_Procedure

End_Object

Send DoWriteData of oRegistry