Can't figure out why TagEventQueue doesn't work in Plant SCADA 2018 R2 (Citect 8.30).
I want to grab changed tags and do something with them. The first step is to read the TagEventQue. And at this step I got stuck.
I'm trying the ExampleSA project, because there are already a lot of tags.
What I did:
1) [IOServer] EnableEventQueue = 1 - did not help get queue handle of the Tag Update Event queue
2) added [Event] Server = 1 - did not work
My code is:
FUNCTION ReadEvents()
INT status;
INT queue;
INT format;
INT eventId;
STRING event;
queue = TagEventQueue();
format = TagEventFormat();
status = QueRead(queue, eventId, event, 1);
//sMsg is STRING variable tag, Disk IODevice, Generic Protocol
sMsg = "Status: " + IntToStr(status) + "eventId: " + IntToStr(eventId);
END
I always get "Status: -1 ..."
Tried to search in KERNEL on the Page Queue. There was never a queue with the name TagEventQueue.
I call the function by pressing a button.
Perhaps this process takes place in isolation from the place where the tag queue operates?
I don't know where to dig