Use the search feature to view Kepware's repository of more than 500 Knowledge Base articles. Narrow your results or type your query into the search field below.

Alternatively, if you are unable to find a solution, we have an additional resource - our PTC eSupport Portal . If you are prompted to log into the eSupport Portal, you can use your My Kepware credentials. Need a My Kepware account? Create one here .

Search Solution Results By:
View All Solutions

Kepware Knowledge Base: Solution

ClientAce Application Is Getting Multiple DataChanged Events For Each Item

Last Update: 11/12/2018
A client application is designed to connect to a server once an hour get data changes before disconnecting. On the first connection, the application gets one DataChanged Event for all of the monitored items. On the next connection, the application gets two DataChanged Events for the monitored items. Each successive connection increases the number of DataChanged Events received for the monitored items. Even though the ClientAce application is creating a new unique connection on every cycle, the application is also creating a new event handler on every cycle. Because that event handler is not part of the server object, it is not destroyed when the application disconnects from the server. This means that the previous event handler still exists on each new connection.

Only initialize the event handlers once on application start-up.
Related Products