04 2008 档案
摘要:Global.asax 文件,有时候叫做 ASP.NET 应用程序文件,提供了一种在一个中心位置响应应用程序级或模块级事件的方法。你可以使用这个文件实现应用程序安全性以及其它一些任务。下面让我们详细看一下如何在应用程序开发工作中使用这个文件。 Global.asax 位于应用程序根目录下。虽然 Visual Studio .NET 会自动插入这个文件到所有的 ASP.NET 项...
阅读全文
摘要:1]避免方法中有超过5个参数的情况。使用结构来传递多个参数。 2]只有是自然结构才能直接使用const,比如一个星期的天数。 3]避免在只读的变量上使用const。如果想实现只读,可以直接使用readonly。 4]每个假设必须使用Assert检查 object obj = GetObject(); Debug.Assert(obj != null); 5]避免方法的返回值是错误代码。 6]只...
阅读全文
摘要:ScriptManager属性和方法如下: 属性/方法 描述 AllowCustomError ...
阅读全文
摘要:using System; namespace Webtest { public interface interface1 { int add(); } public class ReflectTest:interface1 { public String Write; ...
阅读全文
摘要:setAttribute(string name, string value):增加一个指定名称和值的新属性,或者把一个现有的属性设定为指定的值。 设置对象的属性则应该采用: document.getElementById("apple").setAttribute("width","100") document.getElementsByTagName("div")[0].setAttri...
阅读全文
摘要:添加的命名空间:using System.Xml; 1,创建到服务器同名目录下的xml文件: 方法一: XmlDocument xmldoc = new XmlDocument ( ) ; XmlDeclaration xmldecl; xmldecl = xmldoc.CreateXmlDeclaration("1.0","gb2312",null);//加入XML的声明段落, xmldoc...
阅读全文

浙公网安备 33010602011771号