Click or drag to resize
IDeviceManagerAddDevice Method

[This is preliminary documentation and is subject to change.]

Adds a device

Namespace: Netadmin.Management.Inventory
Assembly: Netadmin.Management.Interfaces (in Netadmin.Management.Interfaces.dll) Version: release/9.0@131b654fe7332b0776120c2b44d96c6cac5ac9a2
Syntax
IDevice AddDevice(
	IDevice device,
	long companyId
)

Parameters

device
Type: Netadmin.Management.Inventory.DtoIDevice
The device to add
companyId
Type: SystemInt64
The company id

Return Value

Type: IDevice
The added device
Exceptions
ExceptionCondition
NonUniqueValueExceptionThrown if a device name is not unique
ArgumentExceptionAddDevice can not be used to add devices that are installed in slots. Please use InstallExpansionCard()
ObjectNotFoundExceptionThe device definition must be present in the system.
InvalidIdentifierExceptionThrown if an identifier is zero or lower
InvalidOperationExceptionThrown if the device definition does not have an interface calculation plugin
CompanyMismatchExceptionThrown if the site or customer does not belong to the same company as the device
CalculationExceptionException during interface name calculation
See Also