Skip to content

Add output device to group does not work #3

@ristopii

Description

@ristopii

Seems that when i want to add output device to group, then i get error.
Add-DeviceGroupMember : Unable to cast object of type VideoOS.Platform.ConfigurationItems.Output' to type 'VideoOS.Platform.ConfigurationItems.InputEvent'.

Powershell commands:

PS C:\Windows\system32> get-DeviceGroup -DeviceCategory Output -Path "TestOutput"

OutputFolder      : Outputs
OutputGroupFolder : Output groups
Id                : 10EB3506-2A17-44F5-9068-8B6C9E6209DA
LastModified      : 27.03.2020 11:56:23
BuiltIn           : False
Methods           : {}
ServerId          : VideoOS.Platform.ServerId
Name              : TestOutput
DisplayName       : TestOutput
Path              : OutputGroup[10eb3506-2a17-44f5-9068-8b6c9e6209da]
ParentPath        : /OutputGroupFolder
ItemCategory      : Item
Description       : 
ParentItemPath    : System[]
PS C:\Windows\system32> $dstRS | Get-Hardware | get-Output | where {$_.id -eq "8BE4B799-0308-4008-BAA4-6B446266AB94"}

CustomPropertiesFolder     : Custom properties folder
DeviceDriverSettingsFolder : Device settings
Enabled                    : True
Id                         : 8BE4B799-0308-4008-BAA4-6B446266AB94
Channel                    : 0
CreatedDate                : 01.01.0001 00:00:00
LastModified               : 27.03.2020 11:07:59
GisPoint                   : POINT EMPTY
ShortName                  : 
Icon                       : 0
CoverageDirection          : 0
CoverageDepth              : 0
CoverageFieldOfView        : 0
Methods                    : {ChangeSecurityPermissions}
ServerId                   : VideoOS.Platform.ServerId
Name                       : TestOut
DisplayName                : TestOut
Path                       : Output[8be4b799-0308-4008-baa4-6b446266ab94]
ParentPath                 : Hardware[035c0165-c16e-4c30-a6b8-7446bb34b0ce]/OutputFolder
ItemCategory               : Item
Description                : 
ParentItemPath             : Hardware[035c0165-c16e-4c30-a6b8-7446bb34b0ce]
PS C:\Windows\system32> $dstRS | Get-Hardware | get-Output | where {$_.id -eq "8BE4B799-0308-4008-BAA4-6B446266AB94"}  | get-member

TypeName: VideoOS.Platform.ConfigurationItems.Output
PS C:\Windows\system32> Add-DeviceGroupMember -DeviceCategory Output -Path "TestOutput" -DeviceId "8BE4B799-0308-4008-BAA4-6B446266AB94"
Add-DeviceGroupMember : Unable to cast object of type 'VideoOS.Platform.ConfigurationItems.Output' to type 'VideoOS.Platform.ConfigurationItems.InputEvent'.
At line:1 char:1
+ Add-DeviceGroupMember -DeviceCategory Output -Path "TestOutput" -Devi ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : NotSpecified: (:) [Add-DeviceGroupMember], InvalidCastException
    + FullyQualifiedErrorId : System.InvalidCastException,MilestonePSTools.DeviceGroupCommands.AddDeviceGroupMember

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions