08 2012 档案

摘要:c# 异步更新UI 不阻塞 流畅Task task = Task.Factory.StartNew(() =>{ DoLongRunningWork(); // 耗时运算});Task UITask= task.ContinueWith(() => { this.TextBlock1.Text = "Complete"; //运算后 赋值 }, TaskScheduler.FromCurrentSynchronizationContext());btnStop.Invoke(new Action(delegate() { this.btnStop.Enabled 阅读全文
posted @ 2012-08-23 12:51 曾祥展 阅读(7325) 评论(0) 推荐(0) 编辑
摘要:HttpContext.Current.Session ,出现未将对象引用设置到实例上 using System.Web.SessionState; public class xx: IHttpHandler, IReadOnlySessionState { IReadOnlySessionStat 阅读全文
posted @ 2012-08-16 10:34 曾祥展 阅读(7771) 评论(2) 推荐(0) 编辑