09 2010 档案

摘要:try { RegistryKey hklm = Registry.LocalMachine; RegistryKey run = hklm.CreateSubKey(@"Software\Microsoft\Windows\CurrentVersion\Run"); if (checkBox1.Checked == true) { run.SetValue("thisApplication.ex... 阅读全文
posted @ 2010-09-28 14:31 哑吧湖大水怪 阅读(323) 评论(0) 推荐(0)
摘要:本文为转载 :http://space.itpub.net/12921506/viewspace-466220一、用var定义变量在C#3.0中提供了一种新的声明变量的方式,这就是var。通过这个关键字,在声明变量时就无需指定类型了,变量类型是在初始化时由编译器确定的。代码如下:varss="abcd";MessageBox.Show(ss.GetType().ToString());上面的代码将... 阅读全文
posted @ 2010-09-27 17:01 哑吧湖大水怪 阅读(259) 评论(0) 推荐(0)
摘要:转载自:http://www.cnblogs.com/tishifu/archive/2008/01/03/1024513.html定义以下枚举public enum BookType{ Ticket, Trip, Hotel}从String到enumBookType type = (BookType)Enum.Parse(typeof(BookType),"Ticket");从enum到Stri... 阅读全文
posted @ 2010-09-20 17:52 哑吧湖大水怪 阅读(950) 评论(0) 推荐(0)