04 2014 档案

摘要://获取系统字体:InstalledFontCollection fc = new InstalledFontCollection(); foreach( FontFamily font in fc.Families ){ ListItem tmp = new ListItem( font... 阅读全文
posted @ 2014-04-22 11:21 Micmacs 阅读(1544) 评论(0) 推荐(0) 编辑
摘要:private bool IsAllowedExtension(HttpPostedFile hifile) { bool ret = false; System.IO.FileStream fs = new System.IO.F... 阅读全文
posted @ 2014-04-21 16:50 Micmacs 阅读(370) 评论(0) 推荐(0) 编辑
摘要:System.Diagnostics.Process.Start(); 能做什么呢?它主要有以下几个功能:1、打开某个链接网址(弹窗)。2、定位打开某个文件目录。3、打开系统特殊文件夹,如“控制面板”等。那么它是怎么实现这几个功能的呢?在讲应用前,我们先来看看Process.Star()的构造方法... 阅读全文
posted @ 2014-04-15 10:51 Micmacs 阅读(674) 评论(0) 推荐(0) 编辑
摘要:Image img = Image.FromHbitmap(icon.ToBitmap().GetHbitmap()); Graphics g = Graphics.FromImage(img); g.DrawImage(img, 0, 0, img.Width, img.Height); Font f = new Font("Verdana", 32); Brush b = ne... 阅读全文
posted @ 2014-04-08 11:18 Micmacs 阅读(6364) 评论(0) 推荐(0) 编辑
摘要:/// /// Converts an image into an icon. /// /// The image that shall become an icon /// The width and height of the icon. Standard /// sizes are 16x16, 32x32, 48x48, 64x64. /// Whether the image should be squashed into a /// square or whether whites... 阅读全文
posted @ 2014-04-08 11:17 Micmacs 阅读(624) 评论(0) 推荐(0) 编辑