You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I was able to register my CoAP sensor resource successfully and I get this notification every 30 secs, now I want to display this notification on a windows application, so for every change in state of the resource I want my display field to be updated. How do I handle this ? I see the notifications on wireshark, my windows application should get these notifications. How do I approach this ?
Edwin
The text was updated successfully, but these errors were encountered:
With a Request object marked with Request.MarkObserve(), a Request.Respond event will be fired every time a notification is arrived. You can add a handler to that event to get the notification and update your window. For instance:
// create a new requestRequestrequest;// mark as observer
request.MarkObserve();// add event handler
request.Respond +=delegate(Objectsender,ResponseEventArgse){// this is a new notificationResponseresponse= e.Response;// TODO update window state here// you may need to switch to the UI thread first};// finally issue the request
request.Send();
Hi,
I was able to register my CoAP sensor resource successfully and I get this notification every 30 secs, now I want to display this notification on a windows application, so for every change in state of the resource I want my display field to be updated. How do I handle this ? I see the notifications on wireshark, my windows application should get these notifications. How do I approach this ?
Edwin
The text was updated successfully, but these errors were encountered: