Skip to content

Set custom inventory

Sets custom inventory for a unit.

This function is overloaded, meaning that two separate parameter sets are available;

SetCustomInventory(Byval UnitName as String, Byval UnitType as String, Byval section as String, Byval Name as String, Byval Value as String, Byval DataType as String) as Boolean

SetCustomInventoryUUID(Byval Uuid as String, Byval Section as String, Byval Name as String, Byval Value as String, Byval DataType as String) as Boolean

UnitName (String)

The name of the unit to get custom inventory for

UnitType (String)

The type of unit stated in UnitName. Two different values are accepted;

  • “1” (Computer)
  • Other custom device types

Uuid (String)

The UUID of unit to get custom inventory for in the format;  xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx

Section (String)

Inventory section

Name (String)

Name of the value

Value (String)

The value itself

DataType (String)

The type of data being inserted;

  • “I” = Integer
  • “T” = Time
  • “S” = String
  • “N” = Text

VBScript

Set oCMS = CreateObject("CapaInstaller.SDK")
wscript.echo oCMS.SetDefaultManagementPoint("1")
wscript.echo oCMS.SetCustomInventory("Klient","1","Antivirus","Version","4","I")

VBScript

Set oCMS = CreateObject("CapaInstaller.SDK")
wscript.echo oCMS.SetDefaultManagementPoint("1")
wscript.echo oCMS.SetCustomInventoryUUID("E3FBEC1E-32AC-4E51-AB9F-A644CD9F0A6B", "Antivirus","Version","4","I")