Beispiel #1
0
 /// <summary>
 /// Log a mesage to the Textbox via an Eventhandler.
 /// </summary>
 /// <param name="status"></param>
 /// <param name="endPoint"></param>
 public void LogConsole(string status, IPEndPoint endPoint)
 {
     string text = DateTime.Now.ToString() + ": Client " + endPoint.Address.ToString() + ":" + endPoint.Port + " " + status;
     LogText log = new LogText();
     log.SetText = text;
     Log(this, log);
 }
Beispiel #2
0
 private void addText(Server s, LogText e)
 {
     this.Dispatcher.Invoke(new Action<System.Windows.Controls.TextBox>(TbLog => TbLog.Text += Environment.NewLine + e.SetText.ToString()), this.TbLog);
 }