public event EventHandler<LineStrDataEventArgs> LineDataStrChange; 自定义事件
p.LineDataStrChange += p_LineDataStrChange;
void p_LineDataStrChange(object sender, LineStrDataEventArgs e)
{}
LineDataStrChange(this, new LineStrDataEventArgs(str, this.LineNo));
public class LineStrDataEventArgs : EventArgs
{
public string Value;
public int LineNo;
public LineStrDataEventArgs(string value, int lineNo)
{
this.Value = value;
this.LineNo = lineNo;
}
}