# Reg_SetBinary

> Set the value of a registry variable of type binary.

Source: https://docs.capaone.com/capainstaller/vb-scripting-library/registry-functions/reg-setbinary/  
Product: CapaInstaller — a separate CapaSystems product; do not apply this page to any other.

### Description

Set the value of a registry variable of type binary

### Syntax

Reg_SetBinary(sHandle, sKey, sVariable, vValue) as Boolean

### Parameters

#### sHandle (String)

HKEY-handle

#### sKey (String)

Subkey path

#### sVariable (String)

Name of variable to contain the value

#### vValue (Variant)

Binary value. Must be integers only

### Example

**VBScript**

```vb
Redim aTmp(2)
aTmp(0) = "10"
aTmp(1) = "1"
aTmp(2) = "5"
 
If bStatus Then bStatus = Reg_SetBinary("HKLM", "Software\KeyName", "ValueName", aTmp)
```

[Scripting Guidelines](/capainstaller/vb-scripting-library/scripting-guidelines/)

### Related functions

[Registry Functions](/capainstaller/vb-scripting-library/registry-functions/) [Constants](/capainstaller/vb-scripting-library/addendum/constants/) [Package Property](/capainstaller/vb-scripting-library/addendum/package-property/) [Variables](/capainstaller/vb-scripting-library/addendum/variables/)
