随笔 - 252, 文章 - 13, 评论 - 176, 阅读 - 58万
  博客园  :: 首页  :: 新随笔  :: 联系 :: 订阅 订阅  :: 管理

随笔分类 -  Windows Forms开发

摘要:作用:1、将耗时的操作放在单独的线程,加快UI的响应速度。Thread t = new Thread(delegate() { parse.ParseDay(StockCode, FileName);});t.Start();2、非UI线程操作UI上的控件属性。this.BeginInvoke((T... 阅读全文

posted @ 2015-01-24 21:37 快乐家++ 阅读(371) 评论(0) 推荐(0) 编辑

摘要:WinForm下的ComboBox默认是以多行文本来设定显示列表的, 这通常不符合大家日常的应用,因为大家日常应用通常是键/值对的形式去绑定它的.参考了一些网上的例子,最终写了一个辅助类用于方便对ComboBox的操作:用下面这个类的实例作为ComboBox的添加项:using System;usi... 阅读全文

posted @ 2014-07-10 22:52 快乐家++ 阅读(19883) 评论(0) 推荐(3) 编辑

摘要:.AliceBlue240,248,255.LightSalmon255,160,122.AntiqueWhite250,235,215.LightSeaGreen32,178,170.Aqua0,255,255.LightSkyBlue135,206,250.Aquamarine127,255,2... 阅读全文

posted @ 2014-06-27 10:22 快乐家++ 阅读(905) 评论(0) 推荐(0) 编辑

摘要://方法一:只禁止多个进程运行using System;using System.Collections.Generic;using System.Windows.Forms;namespace DuoYeMianIE{ static class Program { ///... 阅读全文

posted @ 2014-06-15 19:55 快乐家++ 阅读(14646) 评论(2) 推荐(1) 编辑

摘要:private void btnBaoshi_Click(object sender, EventArgs e) { try { System.Threading.Thread thread = ... 阅读全文

posted @ 2014-06-08 11:09 快乐家++ 阅读(1580) 评论(0) 推荐(1) 编辑

摘要:#region 移动窗体 移动窗口 private Point _mousePoint; private int topA(Control cc) { if (cc == null || cc == this) retu... 阅读全文

posted @ 2014-05-14 23:46 快乐家++ 阅读(4101) 评论(0) 推荐(0) 编辑

摘要:using System.Runtime.InteropServices; [DllImport("user32")]private static extern bool AnimateWindow(IntPtr hwnd, int dwTime, int dwFlags); //下面是可用的常量,按照不合的动画结果声明本身须要的private const int AW_HOR_POSITIVE = 0 x0001;//自左向右显示窗口,该标记可以在迁移转变动画和滑动动画中应用。应用AW_CENTER标记时忽视该标记private const int AW_HOR_NEGA 阅读全文

posted @ 2014-03-14 15:23 快乐家++ 阅读(986) 评论(0) 推荐(1) 编辑

该文被密码保护。

posted @ 2013-10-04 11:44 快乐家++ 阅读(2) 评论(0) 推荐(0) 编辑

摘要:在项目中添加引用:msscript.ocx那么在引用节点下会增加一个MSScriptControl组件,下面是他Interop后的所有对象。MSScriptControl.ScriptControl sc = new MSScriptControl.ScriptControl(); sc.Language = "javascript"; object obj = sc.Eval("var no='dd';no"); Messag... 阅读全文

posted @ 2013-02-15 20:34 快乐家++ 阅读(622) 评论(0) 推荐(0) 编辑

摘要://C#查询DNS的MX地址的代码namespace PAB.DnsUtils { using System; using System.Collections; using System.ComponentModel; using System.Runtime.InteropServices; public class DnsMx { public DnsMx() { } [DllImport("dnsapi", EntryPoint="DnsQuery_W", CharSet=CharSet.Unicode, SetLastError=true, E 阅读全文

posted @ 2012-12-07 16:34 快乐家++ 阅读(310) 评论(0) 推荐(0) 编辑

摘要://-----------------------------------------------------------------------------////算法:排列组合类//////调用方法如下:////1.GetPermutation(T[],startIndex,endIndex)/... 阅读全文

posted @ 2011-11-05 08:38 快乐家++ 阅读(352) 评论(0) 推荐(0) 编辑

点击右上角即可分享
微信分享提示