代码如下: using System; using System.Data; using System.Configuration; using System.Text; using System.CodeDom.Compiler; using Microsoft.CSharp; using System.Reflection; namespace EvalGuy { /// summary /// 本类用来将字符串转为可...
理解C#垃圾回收机制我们首先说一下CLR(公共语言运行时,Common Language Runtime)它和Java虚拟机一样是一个运行时环境,核心功能包括:内存管理、程序集加载、安全性、异步处理和线程同...
静态类 vs 普通类 静态类与普通类的区别有以下几点: 1)静态类无法实例化而普通类可以; 2)静态类只能从System.Object基类继承;普通可以继承其它任何非static和非sealed类,但也只能继...
工厂接口定义 复制代码 代码如下: /// summary /// 工厂接口定义 /// /summary /// remarks /// TTarget : abstract product type /// TSource: concrete product type /// /remarks public interface IFactory { #region config and reg...
SET PARSEONLY 检查每个 Transact-SQL 语句的语法并返回任何错误消息,但不编译和执行语句。 SET PARSEONLY { ON | OFF } 当 SET PARSEONLY 为 ON 时,SQL Server 只分析语句。当 SET PARSEONLY 为 OFF 时,SQL S...
key通常可用来快速查找,同时key是区分大小写;value用于存储对应于key的值。Hashtable中key/value键值对均为object类型,所以Hashtable可以支持任何类型的key/value键值对 BRBRBR在哈希表中添加一...
首先要对Microsoft.Web.Administration进行引用,它主要是用来操作IIS7; using System.DirectoryServices; using Microsoft.Web.Administration; 1:首先是对本版IIS的版本进行配置: 复制代码 代码如下: Director...
复制代码 代码如下: //普通委托 DeleteShow ds = new DeleteShow(ShowName); Console.WriteLine(----------------------); Console.WriteLine(普通委托----请输入用户名:); string Name = Console.ReadLine(); Console.WriteLine(ds(Na...
1、页面上添加 复制代码 代码如下: asp:DropDownList ID=DropDownList1 runat=server /asp:DropDownList 2、在head之间 复制代码 代码如下: script type=text/javascript function openwindow(url) { if (url != ) { window.open(u...
代码如下: try { using (TransactionScope tr = new TransactionScope()) { int i = this.customermanager.addCustomer(customer); int j = this.homestatusmanager.updateHomestatus(homestatus); if ((i * j) 0) { MessageBox.Show(记录插入成功!...