2010年1月20日

把错误信息写入系统日志

摘要: 在Global.asax 里,我想让程序一有异常就记录错误信息到Windos的事件查看器里.void Application_Error(object sender, EventArgs e) { Exception lastError = Server.GetLastError(); string errMessage = lastError.ToString(); string logName... 阅读全文
posted @ 2010-01-20 19:43 攀 阅读(362) 评论(1) 推荐(1)

http中错误代码含义

摘要: http错误代码含义: "100" : Continue "101" : witching Protocols "200" : OK "201" : Created "202" : Accepted "203" : Non-Authoritative Information "204" : No Content "205" : Reset Content "206" : Partial Conte... 阅读全文
posted @ 2010-01-20 19:16 攀 阅读(209) 评论(0) 推荐(0)

怎么解决?"/"应用程序中的服务器错误

摘要: 在做一个自定义错误页面时,配置web.config文件 <customErrors mode="On" defaultRedirect="Oooops.aspx"> <error statusCode="500" redirect="Oooops.aspx"></error> </customErrors>页面出错误信息如下:------------... 阅读全文
posted @ 2010-01-20 18:00 攀 阅读(1300) 评论(0) 推荐(0)
2010年1月7日

ToolTip

摘要: Web控件的属性:ToolTip 的用处 和 Html控件的属性 title 的用处是一样的.就是信息提示.实现信息提示换行效果有三种写法:1.ACII十进制的值 &10; (换行) 2.ACII十进制的值 &13;(回车) 3.\nHtml控件:<a href="#" title="aabb">1</a>应用:1.<a href="#" title=... 阅读全文
posted @ 2010-01-07 17:55 攀 阅读(244) 评论(0) 推荐(0)

IIS启动中给ASPNET帐户访问数据库权限

摘要: SQL Server中以windows验证模式登录:1.给ASPNET帐户连接SQL Server的权限 EXEC sp_grantlogin '本机主机名\ASPNET'2.给ASPNET帐户访问数据库的权限 USE 数据库名    EXEC sp_grantdbaccess '本机主机名\ASPNET'3.给ASPNET帐户访问数据库内部对象的权限. EXEC sp_addrolemember... 阅读全文
posted @ 2010-01-07 15:45 攀 阅读(422) 评论(0) 推荐(0)

web.config配置主题

摘要: 配置文件中:<configuration xmlns="http://schemas.microsoft.com/.NetConfiguration/v2.0">指定用于验证配置文件的 XML 架构的 URL。如果未设置此属性,则无法在 Microsoft Visual Studio 中使用 F1 帮助打开配置元素的主题。ASP.NET 2.0 版的默认值为 "http://schem... 阅读全文
posted @ 2010-01-07 14:12 攀 阅读(245) 评论(0) 推荐(0)
2010年1月3日

2010年全新的开始

摘要: 继续深入学习我喜爱的.net和测试技术. 阅读全文
posted @ 2010-01-03 23:19 攀 阅读(139) 评论(0) 推荐(0)