Notice: This forum has been recovered from an old backup, so some content, links, and dates may be outdated. The forum is currently read-only while we restore sign-in and registration functionality. Details

If you find this forum valuable and would like to help keep it online, donations to help cover hosting and domain costs are greatly appreciated, but never expected. You can support the forum through Buy Me a Coffee or Ko-fi. Thank you for helping preserve the EventGhost community.

Sending Events with payload with the Network event sender

If you have a question or need help, this is the place to be.
Post Reply
miljbee
Experienced User
Posts: 146
Joined: Fri Mar 27, 2009 1:29 pm
Location: Orl├®ans, France

Sending Events with payload with the Network event sender

Post by miljbee »

Hello,

here is a "trick" to send events with payload using the standard Network Event Sender.
In the map action, you normally put your event name.

exemple 1 : myEvent will generate TCP.myEvent with 2 strings in the payload. The first one is the ip of the sender, the second one is always "withoutRelease". You won't be able to get rid of those 2 strings without modifying the code of the network event sender, but you can add some others.

exemple 2 : {eg.globals.someVar} will generate TCP.someEvent if eg.globals.someVar=="someEvent". you still get the 2 strings in the payload

exemple 3 (here is the trick !) : {"payload someData\npayload someOtherData\nEventSuffix"} will generate TCP.EventSuffix with 4 strings in the payload. You still get the one with the ip of the sender and "withoutRelease", but the third and fourth strings of the payload will be "someData" and "someOtherData".

Regards,
Attachments
egNetPayload.jpg
miljbee
TCP Events : A Better Network Event Sender/Receiver Plugin.
The Network Event Sender/Receiver in C#
Get events in EG from Google Calendar.
Post Reply