Last active
August 29, 2015 14:01
-
-
Save workmaster2n/c7df734a11f723c32f7b to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public partial class Form1 : Form | |
{ | |
IRemoteEvents remoteServer; | |
RemoteEventsProxy remoteEventsProxy; | |
TcpChannel tcpChan; | |
BinaryClientFormatterSinkProvider clientProv; | |
BinaryServerFormatterSinkProvider serverProv; | |
private string serverURI = "tcp://localhost:1551/QTrackRemoteEvents.Rem"; | |
string m_Text = string.Empty; | |
int m_MeasurementCount = 0; | |
int m_SolutionCount = 0; | |
PointF m_Position = new PointF(); | |
OnNewSolutionCalculatedDelegate NewSolutionCalculatedDelegateLocal; | |
OnNewSolutionCalculatedDelegate NewSolutionCalculatedDelegateRemote; | |
private void Connect(){ | |
try{ | |
NewSolutionCalculatedDelegateLocal = new OnNewSolutionCalculatedDelegate(MyNewSolutionCalculatedHandler); | |
remoteEventsProxy.NewSolutionCalculated += NewSolutionCalculatedDelegateLocal; | |
NewSolutionCalculatedDelegateRemote = new OnNewSolutionCalculatedDelegate(remoteEventsProxy.NewSolutionCalculatedHandler); | |
remoteServer.NewSolutionCalculated += NewSolutionCalculatedDelegateRemote; | |
} | |
} | |
void MyNewSolutionCalculatedHandler(Tag tag) | |
{ | |
//Here is where we would construct the message. tag has everything we need | |
m_SolutionCount++; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment