I want to subscribe check events from our extension app. When a check is closed, I mean a customer makes payment and the cashier closes the check, I want to subscribe that event and get the current check / transaction information. We can manage that by adding an event / delegate function like so;
İt fires the event and shows the message like I want. But how can I get the check object / information that has been paid from the args or sender parameters. I couldn’t find any methods in the args parameter. Maybe I need to subscribe to a different event. If possible, can you help this question with some code examples please ?
Code:
OpsCloseCheckEvent += OnCloseCheckEvent;
private EventProcessingInstruction OnCloseCheckEvent(object sender, OpsCloseCheckEventArgs args)
{
try
{
OpsContext.ShowMessage("check closed");
return (EventProcessingInstruction)0;
}
catch
{
return (EventProcessingInstruction)1;
}
}
İt fires the event and shows the message like I want. But how can I get the check object / information that has been paid from the args or sender parameters. I couldn’t find any methods in the args parameter. Maybe I need to subscribe to a different event. If possible, can you help this question with some code examples please ?