Built a little server close to the Tutorials Parts 1 ... 3.
During startup the configuration of the variable node is set by:
SetVariableConfiguration(nidVariableCount, NodeHandleType.Internal, "MyCounter");
After the server started up, a timer is started which triggers following method:
private void timerElapsed(object sender, System.Timers.ElapsedEventArgs e)
{
Node n = this.FindInMemoryNode(nidVariableCount) ;
if (n != null)
{
n.Write(Attributes.Value, counter++);
}
}
The node seems to be found correctly, i can identify it by some userdata i added to it during startup. Also the attribute is actually updated as i can see the changing value in the debugger. My problem is: In the UA Expert i cannot see any change of the attribute value, it stays 0, no matter how often i trigger th refresh button. What is my mistake?
No update in UA Expert after node.Write(Attributes.Value,...
Moderator: uasdknet
-
- Jr. Member
- Posts: 3
- Joined: 20 May 2015, 09:32
- Support Team
- Hero Member
- Posts: 3072
- Joined: 18 Mar 2011, 15:09
Re: No update in UA Expert after node.Write(Attributes.Value
Hello,
The Node.Write method does not report the DataChanges implicitly. You have to call ReportChanges manually after each value-update:
NodeAttributeHandle handle;
GetNodeHandle(Server.DefaultRequestContext, nidVariableCount, Attributes.Value, out handle);
ReportDataChanges(Server.DefaultRequestContext, handle);
Best regards
Support Team
The Node.Write method does not report the DataChanges implicitly. You have to call ReportChanges manually after each value-update:
NodeAttributeHandle handle;
GetNodeHandle(Server.DefaultRequestContext, nidVariableCount, Attributes.Value, out handle);
ReportDataChanges(Server.DefaultRequestContext, handle);
Best regards
Support Team