Adding our client implementation. Moving server into its own folder.
2 using System.Collections.Generic;
3 using System.ComponentModel;
8 using System.Threading.Tasks;
9 using System.Windows.Forms;
10 using System.ServiceModel;
11 using System.ServiceModel.Channels;
12 using SharpDisplayManager;
14 namespace SharpDisplayClient
16 public partial class MainForm : Form
18 ChannelFactory<SharpDisplayManager.IDisplayService> iChannelFactory;
19 SharpDisplayManager.IDisplayService iClient;
23 InitializeComponent();
26 private void buttonSetText_Click(object sender, EventArgs e)
28 iClient.SetText(0,"Top");
29 iClient.SetText(1, "Bottom");
32 private void MainForm_Load(object sender, EventArgs e)
35 iChannelFactory = new ChannelFactory<SharpDisplayManager.IDisplayService>(
36 new NetNamedPipeBinding(),
38 "net.pipe://localhost/DisplayService"));
40 iClient = iChannelFactory.CreateChannel();