标签:style blog http ar color os sp on div
private delegate int MyMethod(); private int method() { Thread.Sleep(10000); return 100; } private void MethodCompleted(IAsyncResult asyncResult) { if (asyncResult == null) return; textBox1.Text = (asyncResult.AsyncState as MyMethod).EndInvoke(asyncResult).ToString(); } private void button1_Click(object sender, EventArgs e) { MyMethod my = method; IAsyncResult asyncResult = my.BeginInvoke(MethodCompleted, my); }
标签:style blog http ar color os sp on div
原文地址:http://www.cnblogs.com/wonder315/p/4142368.html