Changing the IdType of Child Nodes from Guid to Integer created while instantiating the controller object

Questions regarding the use of the .NET SDK 2.0 for Server or Client development or integration into customer products ...

Moderator: uasdknet

Post Reply
Muralikrx
Jr. Member
Jr. Member
Posts: 3
Joined: 13 Nov 2020, 21:06

Changing the IdType of Child Nodes from Guid to Integer created while instantiating the controller object

Post by Muralikrx »

In my object model, I have assigned numeric (uint) nodeIds (using Server.NextUniquerId) to Controller object, and am creating the object (CreateObject(Server.DefaultRequestContext, CreateObjectSettings).
While creating the controller, all the nodes are also created. But nodes have their NodeIds in Guid. I would like the nodes also to have nodeIds in numeric (integer) format. How do i change this?

User avatar
Support Team
Hero Member
Hero Member
Posts: 3068
Joined: 18 Mar 2011, 15:09

Re: Changing the IdType of Child Nodes from Guid to Integer created while instantiating the controller object

Post by Support Team »

Hello,

You can override the method BaseNodeManager.CreateNodeId (http://documentation.unified-automation.com/uasdkdotnet/3.0.6/html/classUnifiedAutomation_1_1UaServer_1_1BaseNodeManager.html#abf3f2c6b58e79017ae81bf1edd90f40c) to set the NodeIds of the children of an instance.
Best regards
Unified Automation Support Team

Post Reply