Preview 类外 public delegate void DeviceEventHandler(string s);
Preview 类里 public event DeviceEventHandler OnDeviceEvent;
Preview 发生事件时通知 if (OnDeviceEvent != null) OnDeviceEvent(str);
Preview p = new Preview();
注册事件p.OnDeviceEvent += new DeviceEventHandler(OnDeviceEvent);
接收到事件通知后执行的方法
private void OnDeviceEvent(string s)
{
this.tsslStatus.Text = s;
}