摘要: public class WeatherModel { #region 定义成员变量 private string _temperature = ""; private string _weather = ""; private string _wind = ""; private string _city = ""; private DateTime _dateStart = DateTime.Now; private string _coldPoint = ""; private strin 阅读全文
posted @ 2013-01-09 14:48 liyx0618 阅读(194) 评论(0) 推荐(0) 编辑
摘要: public static classPageBase { public static String MD5(String input) { System.Security.Cryptography.MD5 md5 = new System.Security.Cryptography.MD5CryptoServiceProvider(); byte[] bytes = System.Text.Encoding.UTF8.GetBytes(input); bytes = md5.ComputeHash(bytes); md5.Clear(); string ret = ""; 阅读全文
posted @ 2013-01-09 10:20 liyx0618 阅读(1281) 评论(0) 推荐(0) 编辑
摘要: //Panel重写(不闪烁) public class BackgroundPanel : Panel { public BackgroundPanel() { this.SetStyle(ControlStyles.AllPaintingInWmPaint | //不擦除背景 ,减少闪烁 ControlStyles.OptimizedDoubleBuffer | //双缓冲 ControlStyles.UserPaint, //使用自定义的重绘事件,减少闪烁 true); //设置值 } }//页面布局 partial class test2 { /// <summary> // 阅读全文
posted @ 2013-01-09 09:58 liyx0618 阅读(4002) 评论(0) 推荐(0) 编辑
摘要: DateTime Time; private void timer_Tick(object sender,EventArgs e) { this.Time = DateTime.Now; Invalidate(); } private void UCTime_Paint(object sender, PaintEventArgs e) { Graphics dc = e.Graphics; Pen pn = new Pen(ForeColor); SolidBrush br = new SolidBrush(ForeColor); InitCoordinates(dc); //设置绘画的... 阅读全文
posted @ 2013-01-09 09:29 liyx0618 阅读(338) 评论(0) 推荐(0) 编辑