Dict.CN 在线词典, 英语学习, 在线翻译

天道酬勤

用一辈子做好一件事

2007年5月31日

关于sqlserver 事务的文章

     摘要: 很不错。   阅读全文

posted @ 2008-08-21 14:35 Robot·H 阅读(32) | 评论 (0)编辑

SET XACT_ABORT 详解

     摘要: 事务系列1  阅读全文

posted @ 2008-08-21 14:25 Robot·H 阅读(3) | 评论 (0)编辑

一个小技巧[sql]

     摘要: 您知道吗?  阅读全文

posted @ 2008-08-21 09:54 Robot·H 阅读(80) | 评论 (0)编辑

MSSQL查询题

     摘要: 肥羊的MSSQL详解  阅读全文

posted @ 2008-08-20 17:25 Robot·H 阅读(55) | 评论 (0)编辑

项目启动时出现"the operation timed out "

     摘要: 整死我了也~。。~  阅读全文

posted @ 2008-08-20 15:22 Robot·H 阅读(6) | 评论 (0)编辑

无法在web服务器上启动调试,问题解决

     摘要: 整死我了~。。~  阅读全文

posted @ 2008-08-20 14:58 Robot·H 阅读(7) | 评论 (0)编辑

asp无限级分类 [老早的文章了]

     摘要: 备份一份!  阅读全文

posted @ 2008-08-19 16:07 Robot·H 阅读(17) | 评论 (0)编辑

msSQL2005数据库备份

     摘要: backup   阅读全文

posted @ 2008-08-18 10:07 Robot·H 阅读(128) | 评论 (2)编辑

预警度测试报告书

     摘要: --不死的癌症  阅读全文

posted @ 2008-08-15 14:24 Robot·H 阅读(477) | 评论 (5)编辑

Agile Principles,Patterns,And Practices in C# 之Strategy Pattern

     摘要: 策略模式  阅读全文

posted @ 2008-08-12 16:24 Robot·H 阅读(65) | 评论 (0)编辑

Agile Principles,Patterns,And Practices in C# 之保龄球积分

     摘要: 保龄球积分  阅读全文

posted @ 2008-08-11 11:32 Robot·H 阅读(70) | 评论 (0)编辑

程序人生—非常讨人喜欢的27个原则(转)

     摘要: 学会打交道  阅读全文

posted @ 2008-08-11 10:33 Robot·H 阅读(203) | 评论 (6)编辑

Agile Principles,Patterns,And Practices in C# 之敏捷软件开发宣言

     摘要: 团队的力量是无穷的~。。~  阅读全文

posted @ 2008-08-11 10:11 Robot·H 阅读(89) | 评论 (0)编辑

Agile Principles,Patterns,And Practices in C# 之OCP源代码

     摘要: OCP:OPen-Clsoed Principle Open for Extension Closed For Modification  阅读全文

posted @ 2008-08-11 10:06 Robot·H 阅读(73) | 评论 (0)编辑

动态sql

     摘要: 容易混淆的东东.  阅读全文

posted @ 2008-08-07 16:59 Robot·H 阅读(13) | 评论 (0)编辑

function-loadXmlDoc

     摘要: dom-load实例  阅读全文

posted @ 2008-08-07 10:34 Robot·H 阅读(11) | 评论 (0)编辑

What Great .NET Developers Ought To Know (More .NET Interview Questions)

     摘要: 你必须知道的。  阅读全文

posted @ 2008-08-06 16:15 Robot·H 阅读(71) | 评论 (0)编辑

古老的话题-行专列

     摘要: 如果您不知道,就看看吧。  阅读全文

posted @ 2008-08-06 16:01 Robot·H 阅读(101) | 评论 (0)编辑

开心网莫非是大杂烩

     摘要: kaixin001  阅读全文

posted @ 2008-08-06 09:51 Robot·H 阅读(125) | 评论 (0)编辑

红枣花生蜜

     摘要: 红枣+花生+蜂蜜  阅读全文

posted @ 2008-08-04 17:33 Robot·H 阅读(14) | 评论 (0)编辑

阅读过的书和正在阅读的书

     摘要:   阅读全文

posted @ 2008-08-04 15:13 Robot·H 阅读(158) | 评论 (0)编辑

Enterprise Library 代码生成工具

     摘要: 下载工具  阅读全文

posted @ 2008-08-04 14:10 Robot·H 阅读(220) | 评论 (4)编辑

调查

     摘要: 调查一下!  阅读全文

posted @ 2008-08-04 12:00 Robot·H 阅读(131) | 评论 (0)编辑

2个不错的工具

AudioConverter

Solid Converter pdf

posted @ 2008-08-04 09:04 Robot·H 阅读(20) | 评论 (0)编辑

今天晚上吃什么菜

     摘要: 准备吃它了。  阅读全文

posted @ 2008-08-02 18:51 Robot·H 阅读(130) | 评论 (2)编辑

Validating With the XML Parser

     摘要: validateOnParse parseError  阅读全文

posted @ 2008-08-01 14:14 Robot·H 阅读(17) | 评论 (0)编辑

TSQL LAB 2 - Writing Conditional WHERE Clauses

     摘要: About Query  阅读全文

posted @ 2008-07-31 18:30 Robot·H 阅读(116) | 评论 (0)编辑

C# XML入门经典——C#编程人员必备的XML技能

     摘要: beginning C# xml list  阅读全文

posted @ 2008-07-31 16:58 Robot·H 阅读(87) | 评论 (0)编辑

Xml Parser

     摘要: Xml Parser  阅读全文

posted @ 2008-07-31 15:16 Robot·H 阅读(96) | 评论 (0)编辑

亚马逊的神话

     摘要: AMAZON 系列1  阅读全文

posted @ 2008-07-31 10:39 Robot·H 阅读(130) | 评论 (1)编辑

马云视频集

     摘要: 喜欢马云的进来!  阅读全文

posted @ 2008-07-31 09:49 Robot·H 阅读(125) | 评论 (1)编辑

How to use HttpWebRequest and HttpWebResponse in .NET

     摘要: HtttpWebRequest初体验  阅读全文

posted @ 2008-07-29 18:01 Robot·H 阅读(122) | 评论 (0)编辑

ajax post测试

     摘要: ajax post实例!  阅读全文

posted @ 2008-07-29 14:14 Robot·H 阅读(76) | 评论 (0)编辑

facebook

     摘要: 我的天!  阅读全文

posted @ 2008-07-25 17:40 Robot·H 阅读(99) | 评论 (1)编辑

贝塔斯曼唇亡,当当卓越齿寒

     摘要: 唇亡齿寒否?  阅读全文

posted @ 2008-07-25 14:15 Robot·H 阅读(143) | 评论 (3)编辑

电子商务网站

卓越网: http://www.amazon.cn/
淘宝网: http://taobao.com
当当网: http://home.dangdang.com/
京东  : http://www.360buy.com/
拍拍  : http://www.paipai.com/
易趣  : http://www.eachnet.com/

垂直网站:...

posted @ 2008-07-25 11:41 Robot·H 阅读(31) | 评论 (3)编辑

SNS 网站

     摘要: sns网站列表  阅读全文

posted @ 2008-07-25 11:30 Robot·H 阅读(116) | 评论 (3)编辑

[转帖]淘宝开放平台Taobao Open Platform的机会

     摘要: 马云的策略1-开发自己的平台  阅读全文

posted @ 2008-07-25 10:47 Robot·H 阅读(102) | 评论 (0)编辑

理财

     摘要: 专家教你理财  阅读全文

posted @ 2008-07-25 09:50 Robot·H 阅读(58) | 评论 (0)编辑

Enterprise Library系列文章回顾与总结

     摘要: 不错的Enterprise Library系列!   阅读全文

posted @ 2008-07-24 16:43 Robot·H 阅读(107) | 评论 (0)编辑

Data Access Application block

     摘要: Enterprise library  阅读全文

posted @ 2008-07-24 16:24 Robot·H 阅读(12) | 评论 (0)编辑

端口

     摘要:   阅读全文

posted @ 2008-07-23 14:22 Robot·H 阅读(67) | 评论 (0)编辑

写技术文档的朋友来着看看

     摘要:   阅读全文

posted @ 2008-07-23 13:54 Robot·H 阅读(129) | 评论 (4)编辑

小R每日一句英语

     摘要:   阅读全文

posted @ 2008-07-22 08:57 Robot·H 阅读(18) | 评论 (0)编辑

DOM:element.addEventListener

     摘要: o(∩_∩)o...  阅读全文

posted @ 2008-07-21 17:52 Robot·H 阅读(131) | 评论 (0)编辑

35句话,不看你后悔!

     摘要: 看看吧。   阅读全文

posted @ 2008-07-21 16:59 Robot·H 阅读(212) | 评论 (2)编辑

你触发了谁?

     摘要: 都是浏览器惹得祸。  阅读全文

posted @ 2008-07-21 16:12 Robot·H 阅读(24) | 评论 (0)编辑

Music_北京欢迎您

     摘要:   阅读全文

posted @ 2008-07-18 16:48 Robot·H 阅读(57) | 评论 (0)编辑

[转]新三十年目睹之怪现状

     摘要: 生活真他妈的难  阅读全文

posted @ 2008-07-18 13:29 Robot·H 阅读(104) | 评论 (2)编辑

字符换行

     摘要: 你会字符换行吗?  阅读全文

posted @ 2008-07-15 17:32 Robot·H 阅读(69) | 评论 (0)编辑

您是如何读取模板的?

     摘要: Reader啊!  阅读全文

posted @ 2008-07-09 18:31 Robot·H 阅读(189) | 评论 (0)编辑

大家讨论一下这个图如何设计程序。

     摘要: 看看涵盖那些设计模式。。。。
  阅读全文

posted @ 2008-07-04 22:12 Robot·H 阅读(534) | 评论 (18)编辑

[转帖].Net pet shop 4 和 MSMQ

     摘要: 你的MSMQ Run 了吗?  阅读全文

posted @ 2008-07-04 16:48 Robot·H 阅读(153) | 评论 (1)编辑

ADO.NET Connection Pooling at a Glance

     摘要: 不错的e文!想了解连接池的可以看看。
  阅读全文

posted @ 2008-07-04 10:41 Robot·H 阅读(121) | 评论 (0)编辑

好雨知时节

     摘要: 不错js日历控件!  阅读全文

posted @ 2008-07-02 14:16 Robot·H 阅读(142) | 评论 (0)编辑

一个问题的解决过程。

     摘要: 我已困惑已久!  阅读全文

posted @ 2008-07-01 17:31 Robot·H 阅读(154) | 评论 (2)编辑

document.getElementById为空或不是对象的解决方法

     摘要: 大家经常会出现这样的情况!  阅读全文

posted @ 2008-06-30 08:44 Robot·H 阅读(244) | 评论 (1)编辑

IE8Beta1

http://www.microsoft.com/windows/products/winfamily/ie/ie8/default.mspx

大家可以尝试一下!

posted @ 2008-06-30 08:22 Robot·H 阅读(122) | 评论 (0)编辑

点你2次才有反应

描述:
1:一个页面有三层z-index[1,2,3]
div1:有个按钮OpenDiv,当点击时,弹出div2[遮罩层zindex=2]和一个动态createElement("table")[zindex=3]
2:table里有一个按钮[type=button],点击这个按钮div2和table都被remove掉


    //删除遮蔽层 EnvelopLayer
        var layerBeta=document.getElementById("EnvelopLayer");
        layerBeta.parentNode.removeChild(layerBeta);
    //删除table
    var divid=2;
        var tbl=document.getElementById("Window_"+divid);
        tbl.parentNode.removeChild(tbl);

3:这个页面是aspx页面
问题:这个按钮点2次才起作用。不知道为什么?
如果是html页面,点击一次就会起作用。
可为什么aspx页面就2次呢?


note:<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">都一样.

部分js代码

建立遮罩层

function createEnvelopLayer()
{
    var h=document.documentElement.clientHeight;
    var w=document.documentElement.clientWidth;
    var div=document.createElement("<div id='EnvelopLayer' style='position:absolute;visibility:visible;background:#000;filter:alpha(opacity=20);z-index:500;left:0;top:0;width:"+w+"px;height:"+h+"px;color:#fff'></div>");
    div.id="EnvelopLayer";
    document.body.appendChild(div);
}

 

//create table

this.oTable = document.createElement("table");
   
    this.oTable.id = "Window_" + this.id;
 
 this.oTable.style.width = this.width + "px";
 //this.oTable.style.height = "100px";
 //set zIndex
 this.oTable.style.zIndex="1000"
 
 //this.oTable.style.width = "100%";
 //this.oTable.style.height = document.body.scrollHeight
 //this.oTable.style.border = "1px solid #C2C3BD";
  this.oTable.cellSpacing = 0;
 //this.oTable.cellPadding = 2;
 this.oTable.cellPadding = 0;
 //this.oTable.border = 0;
 //this.oTable.style.backgroundColor = "#FFFFFF";

 // determine the windows position when first open
 this.oTable.style.position = "absolute";
 this.oTable.style.left = this.x + "px";
 this.oTable.style.top = this.y + "px";

 // link from the table to the JSWindow object
 this.oTable.jsWindow = this;

 // if the table is clicked anywhere, show the table in front of other open windows
 this.oTable.onmousedown = JSWindow.prototype.onBringToFront;
    this.oTable.className="tanchu";

 

this.oContentTD.innerHTML = document.all["Div" + this.id].innerHTML;

posted @ 2008-06-29 12:38 Robot·H 阅读(132) | 评论 (1)编辑

return false

     摘要: 可爱可恨的return false;  阅读全文

posted @ 2008-06-27 15:36 Robot·H 阅读(118) | 评论 (5)编辑

CSS Properties To JavaScript Reference Conversion

     摘要: 发上来、方便查阅!  阅读全文

posted @ 2008-06-27 11:53 Robot·H 阅读(122) | 评论 (0)编辑

随机数

     摘要: 随即数 !  阅读全文

posted @ 2008-06-25 17:49 Robot·H 阅读(120) | 评论 (0)编辑

一个生成Validatecode 的代码。

     摘要: Bitmap,Graphics,Random等的使用!  阅读全文

posted @ 2008-06-25 17:39 Robot·H 阅读(40) | 评论 (0)编辑

JavaScript replace() 方法

     摘要: replace 的使用小结!  阅读全文

posted @ 2008-06-24 17:35 Robot·H 阅读(299) | 评论 (0)编辑

完美的Div弹出窗口

     摘要: 完美不完美你说了算!  阅读全文

posted @ 2008-06-24 15:28 Robot·H 阅读(434) | 评论 (9)编辑

js_Div Popup

     摘要: js Popup  阅读全文

posted @ 2008-06-23 17:57 Robot·H 阅读(45) | 评论 (0)编辑

js中的面向对象.

     摘要: js中的面向对象!  阅读全文

posted @ 2008-06-23 13:34 Robot·H 阅读(149) | 评论 (0)编辑

正则表达式30分钟入门教程

     摘要: RegularExpression  阅读全文

posted @ 2008-06-22 21:53 Robot·H 阅读(28) | 评论 (1)编辑

孩子他爸

     摘要: 回忆瘸狼  阅读全文

posted @ 2008-06-22 20:12 Robot·H 阅读(144) | 评论 (0)编辑

Using SingleTagSectionHandler Instead Of appSettings

     摘要: 配置节点!  阅读全文

posted @ 2008-06-22 00:26 Robot·H 阅读(116) | 评论 (0)编辑

js值得收藏

     摘要: js经典收藏!  阅读全文

posted @ 2008-06-21 23:35 Robot·H 阅读(253) | 评论 (4)编辑

控件的局部验证

     摘要: VS2005有ValidationGroup,
VS2003有什么?  阅读全文

posted @ 2008-06-21 23:14 Robot·H 阅读(125) | 评论 (0)编辑

法从路径“...”打开“...”处的项目文件夹。返回的错误是: 无法打开Web项目“”。返回的错误是: 无法打开Web项目

     摘要: 有恨有爱的VSWebCache  阅读全文

posted @ 2008-06-18 17:12 Robot·H 阅读(29) | 评论 (0)编辑

试图运行项目时出错:无法在web服务器上启动项目得解决办法

     摘要: debug  阅读全文

posted @ 2008-06-18 15:15 Robot·H 阅读(22) | 评论 (0)编辑

Sichuan reopens to tourists, full recovery by 2010

From :ChinaDaily
URL:http://www.chinadaily.com.cn/china/2008-06/15/content_6761484.htm

Sichuan reopens to tourists, full recovery by 2010

By Huang Zhiling and Luo Xianyu (chinadaily.com.cn)
Updated: 2008-06-15 16:22


Soliders, policeman and volunteers who helped Dujiangyan's quake relief receive "gold cards" from the city's government June 15, 2008. The cardholders will be able to visit the Dujiangyan Irrigation Project and Mount Qingcheng free of charge during their lifetime. [Huang Zhiling/chinadaily.com.cn] 

CHENGDU: He Ping, a 52-year-old taxi driver in Chengdu, capital of Sichuan Province, sent a passenger to the Lidui Park in this city 48 km northwest of Chengdu early Sunday morning.

When he found the park which is home to Dujiangyan, the world's oldest irrigation project still in operation, was open to visitors free of charge, he made a quick visit to the site of the project on the World Cultural Heritage List of the United Nations Educational, Scientific and Cultural Organization.

Special coverage:
Strong Earthquake Jolts China

Related readings:
Frugal life for pandas in Chengdu
China quake death toll rises to 69,170
Panda safety main concern of rangers
54 tourists dead in China earthquake

"To my pleasant surprise, only some bricks and tiles have fallen from buildings near the project site and glass encircling a stone statue of Li Bing (builder of the project) built in the Eastern Han Dynasty (AD 25-220) has been shattered. And the dam site is intact," he said.

According to Cui Wei, an official with the Dujiangyan irrigation project administrative bureau, the park will be open free of charge for three months to promote tourism hard hit by the May 12 earthquake.

"The promotion is in response to the Sichuan Provincial Tourism Administration's decision to partially reopen the provincial tourism market on June 15," he said.

On May 12, the National Tourism Administration asked individuals and tour groups not to visit Sichuan in the wake of the earthquake.

Sichuan reopened 12 cities and one prefecture to tourists on Sunday in a move to revive its once-booming tourism industry. They include Zigong, Panzhihua, Luzhou, Suining, Neijiang, Leshan, Nanchong, Yibin, Guang'an, Dazhou, Meishan and Ziyang and the Liangshan Yi autonomous prefecture.

It partially opened Chengdu to tourists, for several major visitors' attractions were damaged in the earthquake, said Zhang Gu, chief of the Sichuan provincial tourism administration.

"Sichuan will promote visits to its attractions by locals in the province and ask provinces and cities which are helping Sichuan in its after-quake reconstruction to organize tourists to Sichuan," he told chinadaily.com.cn.

Sichuan's tourism sector has suffered a loss of more than 50 billion yuan (US$7.2 billion) because of the earthquake. But it has not caused havoc to the province's world heritage sites.

Mount Qingcheng and Dujiangyan have been just partly damaged, while the Jiuzhaigou and Huanglong scenic spots, Mount Emei and the Leshan Giant Buddha have suffered no damage in the earthquake.

Sichuan is working on the reconstruction plan of its tourism sector. According to the plan, the sector's full recovery, which is expected to take two years, will be in several steps.

First, the province will stress the promotion of the Chengdu-Mount Emei-Leshan Giant Buddha route in the second half of this year to show Sichuan is safe. Second, it will stress the promotion of the sector in an all-round way next year. The entire tourism sector including in disaster areas is expected to fully recover in about 2010.

The worst-hit places, including Beichuan county, Tangjiashan earthquake lake area, and Hanwang town, are expected to be built into earthquake museums in three years, he said.

The province will raise nearly 200 billion (nearly US$29 billion) from both the governments and investors for the reconstruction of the sector, according to the plan.

Tourism revenue in Sichuan was 121.7 billion yuan (US$18 billion) last year, accounting for 11.6 percent of the province's gross domestic product. More than 400,000 people are working in the industry.

Some visitors' attractions reopened to visitors before June 15, the timetable for their reopening set by his bureau because they were eager to restore their former prosperity, Zhang said.

The Lidui Park reopened on June 14 and was visited by some 4,000 tourists from Chengdu, Chongqing Municipality, Guizhou Province and Guangzhou.

In a ceremony marking the park's reopening, the Dujiangyan municipal government presented 100 "gold cards" to soldiers, policemen, medics, volunteers, donors, journalists and representatives from international organizations to appreciate their contribution to relief work in the city.

With the cards, holders who have contributed to relief work can visit the Dujiangyan Irrigation Project and Mount Qingcheng, which is birthplace of Taoism, the only religious indigenous to China, free of charge during their lifetime.

The issuance of the cards will not be limited. "The city will issue the cards to all those who have helped its relief work. They will post them to those who have left Dujiangyan," said Liu Junlin, party chief of Dujiangyan.

He said at least 1 million people have participated in relief work in his city.


生词
irrigation :灌溉
Heritage :遗产
Eastern Han Dynasty  :朝代
shattered:粉碎[eeter]
dam :水贝
intact:完整无缺的。
bureau:办公署
promote :促进.
tourism :旅游
prefecture :辖区
timetable :时刻表
issuance:发布

posted @ 2008-06-15 23:29 Robot·H 阅读(26) | 评论 (0)编辑

菟丝子的问题。

     摘要: 利用@@ROWCOUNT和Depth实现该功能。  阅读全文

posted @ 2008-06-14 18:44 Robot·H 阅读(150) | 评论 (0)编辑

Petshop的一个疑惑

     摘要: PetShop中的一点小疑惑。  阅读全文

posted @ 2008-06-13 11:33 Robot·H 阅读(89) | 评论 (1)编辑

ShoppingCart

     摘要: go,go,go!  阅读全文

posted @ 2008-06-12 16:17 Robot·H 阅读(20) | 评论 (0)编辑

如何把string解析为int?[C#]

     摘要: string-------------->int  阅读全文

posted @ 2008-06-10 22:42 Robot·H 阅读(87) | 评论 (0)编辑

判断字符串为空的最有效的方法。

     摘要: 字符串是否为空的判断  阅读全文

posted @ 2008-06-10 22:21 Robot·H 阅读(37) | 评论 (0)编辑

看似简单的问题 静态方法和实例化方法的区别

     摘要: Static variable  阅读全文

posted @ 2008-06-05 14:30 Robot·H 阅读(64) | 评论 (0)编辑

面试2

     摘要: C#基础  阅读全文

posted @ 2008-06-03 23:31 Robot·H 阅读(28) | 评论 (0)编辑

StategyPattern

     摘要: 吕老师经典的设计模式讲解  阅读全文

posted @ 2008-05-31 10:27 Robot·H 阅读(18) | 评论 (0)编辑

VS2005(Visual Studio 2005)中命令窗口的使用

     摘要: debug多多  阅读全文

posted @ 2008-05-29 12:30 Robot·H 阅读(176) | 评论 (0)编辑

如何实现foreach

     摘要: yield return 功不可没  阅读全文

posted @ 2008-05-28 10:28 Robot·H 阅读(188) | 评论 (0)编辑

params(C# 参考)

     摘要: 你有可能熟悉out,ref.你熟悉params吗?不知道可以看看。  阅读全文

posted @ 2008-05-28 10:20 Robot·H 阅读(173) | 评论 (0)编辑

C# 中的委托和事件

     摘要: Delegate经典诠释  阅读全文

posted @ 2008-05-27 09:42 Robot·H 阅读(27) | 评论 (0)编辑

面试1

     摘要: 杀手锏  阅读全文

posted @ 2008-05-24 19:54 Robot·H 阅读(237) | 评论 (11)编辑

完善了一下一个哥们的面试题

     摘要: 看看吧。  阅读全文

posted @ 2008-05-24 12:33 Robot·H 阅读(335) | 评论 (5)编辑

AppDomain From msdn

     摘要: AppDomain知识  阅读全文

posted @ 2008-05-24 11:38 Robot·H 阅读(23) | 评论 (0)编辑

DataReader VS DataSet[转载]

     摘要: 不知道谁写的了。  阅读全文

posted @ 2008-05-23 13:02 Robot·H 阅读(66) | 评论 (0)编辑

何时声明抽象类

     摘要: 很简单的一个问题。  阅读全文

posted @ 2008-05-22 18:08 Robot·H 阅读(223) | 评论 (2)编辑

看美女想到的

     摘要: 观察美丽少妇的后果  阅读全文

posted @ 2008-05-22 12:14 Robot·H 阅读(314) | 评论 (0)编辑

【已经找到】准备找工作了[北京地区C#]

     摘要: MyResume  阅读全文

posted @ 2008-05-22 08:38 Robot·H 阅读(719) | 评论 (9)编辑

TRULY Understanding ViewState

     摘要: 不错的一篇关于ViewState的E文文章。  阅读全文

posted @ 2008-05-12 16:05 Robot·H 阅读(120) | 评论 (0)编辑

献给母亲的礼物

     摘要: 献给母亲  阅读全文

posted @ 2008-05-11 11:10 Robot·H 阅读(103) | 评论 (2)编辑

析构函数(C# 编程指南)

     摘要: ~  阅读全文

posted @ 2008-05-09 10:59 Robot·H 阅读(51) | 评论 (0)编辑

using做了什么?

C# 编程语言的 using 语句通过简化必须编写以便创建和清理对象的代码,使得对 Dispose 方法的调用更加自动化。using 语句获得一个或多个资源,执行您指定的语句,然后处置对象。请注意,using 语句只适用于这样的对象:这些对象的生存期不超过在其中构建这些对象的方法。下面的代码示例将创建并清理 ResourceWrapper 类的实例,如 C# 示例实现 Dispose 方法中所示。

 

class myApp
{
   
public static void Main()
   
{
      
using (ResourceWrapper r1 = new ResourceWrapper())
      
{
         
// Do something with the object.
         r1.DoSomething();
      }

   }

}

以上合并了 using 语句的代码与下面的代码等效。

 

 

class myApp
{
   
public static void Main()
   
{
      ResourceWrapper r1 
= new ResourceWrapper();
      
try
      
{
         
// Do something with the object.
         r1.DoSomething();
      }

      
finally
      
{
         
// Check for a null resource.
         if (r1 != null)
         
// Call the object's Dispose method.
         r1.Dispose();
      }

   }

}

posted @ 2008-05-09 10:52 Robot·H 阅读(203) | 评论 (3)编辑

Dispose的一种是实现

     摘要: usingSystem;usingSystem.IO;classProgram{staticvoidMain(){try{//InitializeaStreamresourcetopass//totheDisposableResourceclass.Console.Write("Enterfilenameanditspath:");stringfileSpec=Console.ReadLine()... 阅读全文

posted @ 2008-05-09 10:23 Robot·H 阅读(16) | 评论 (0)编辑

【转】托管资源VS非托管资源 控件VS组件

     摘要: 概念性的东东。  阅读全文

posted @ 2008-05-08 22:33 Robot·H 阅读(132) | 评论 (0)编辑

Select DISTINCT on DataTable

     摘要: In a project I'm doing I needed to basically do a DISTINCT on a couple fields in a DataTable that I had used earlier in code. Did some Google searching and came up with this MS KB on the subject. I was hoping to find it in the Framework, but hey, writing a little extra code never hurt anyway. Looking over the code though I found that I just didn't really like it. Biggest reason being it only took one field. I wanted to be able to pass in n number of fields, so I rewrote it and did a little   阅读全文

posted @ 2008-05-05 19:38 Robot·H 阅读(128) | 评论 (4)编辑

DemonstrateMergeDataTable

     摘要: From:MSDN ExampleprivatestaticvoidDemonstrateMergeTable(){//Demonstratemerging,withinandwithout//preservingchanges.//Inthisexample,taketheseactions://1.CreateaDataTable(table1)andfillthetablewithdata.... 阅读全文

posted @ 2008-05-04 20:01 Robot·H 阅读(13) | 评论 (1)编辑

DataTable部分代码

     摘要: //CreateDataTableDataTabledt=newDataTable();dt.CaseSensitive=true;//CreateDataColumnsDataColumncol1=newDataColumn("id",typeof(int));DataColumncol2=newDataColumn("UserName",typeof(string));//ConfigProp... 阅读全文

posted @ 2008-05-04 18:51 Robot·H 阅读(27) | 评论 (0)编辑

IList--->DataTable

     摘要: usingSystem.Collections;usingSystem.Reflection;usingSystem.Data;usingSystem;publicclassCADataConverter{privatestaticHashtabletypes=newHashtable();privateCADataConverter(){}publicstaticDataTableToDataT... 阅读全文

posted @ 2008-05-03 19:37 Robot·H 阅读(36) | 评论 (0)编辑

[转帖]ExecuteNonQuery方法-小心使用

from:http://www.cnblogs.com/David-weihw/archive/2006/11/17/563701.html
今天我的同事,被ExecuteNonQuery 方法给困住了。
   
    同事只知道ExecuteNonQuery返回受影响的行数,但不知道对于SQL 的 select命令返回值为-1。
     
   更准确的说法是

       对于 UPDATEINSERT DELETE   SQL 语句,返回值为该命令所影响的行数。对于所有其他类型的语句,返回值为 -1。如果发生回滚,返回值也为 -1
  
     对于上面的说法,还有一点很重要:如果你使用的是存储过程,一定不要使用 SET NOCOUNT ON
      否则,返回的值仍为-1。(在.NET 1.1上测试过


【总结】哪怕是再简单的问题都要彻底搞明白,不要一知半解。

posted @ 2008-05-01 11:01 Robot·H 阅读(33) | 评论 (0)编辑

SqlConnection建立的一种方法

ConnectionStringSettings setting = new ConnectionStringSettings();
        setting 
= ConfigurationManager.ConnectionStrings["Codematic"];
        DbProviderFactory facotory 
= DbProviderFactories.GetFactory(setting.ProviderName);
        IDbConnection connection 
= facotory.CreateConnection();
        connection.ConnectionString 
= setting.ConnectionString;
        connection.Open();
        SqlTransaction st 
= connection.BeginTransaction();
        
//Execute more sql
        st.Commit();
        connection.Close();

posted @ 2008-05-01 10:30 Robot·H 阅读(18) | 评论 (0)编辑

Prototype

     摘要: Code From TerryLeeusingSystem;usingSystem.Collections;usingSystem.IO;usingSystem.Runtime.Serialization;usingSystem.Runtime.Serialization.Formatters.Binary;[Serializable]abstractclassColorPrototype{pub... 阅读全文

posted @ 2008-04-30 11:59 Robot·H 阅读(20) | 评论 (0)编辑

ASP.NET中TreeView控件使用小结

     摘要: IEWebControl  阅读全文

posted @ 2008-04-29 16:20 Robot·H 阅读(138) | 评论 (0)编辑

[原创+真实经历]回忆我的大学生活

     摘要: 大学啊、大学!  阅读全文

posted @ 2008-04-28 18:08 Robot·H 阅读(294) | 评论 (6)编辑

XmlTextReader例子

     摘要: usingSystem;usingSystem.Data;usingSystem.Configuration;usingSystem.Collections;usingSystem.Web;usingSystem.Web.Security;usingSystem.Web.UI;usingSystem.Web.UI.WebControls;usingSystem.Web.UI.WebControls... 阅读全文

posted @ 2008-04-19 12:38 Robot·H 阅读(67) | 评论 (1)编辑

How do I iterate through a form collection?

     摘要: asp的一个小东东。。。  阅读全文

posted @ 2008-04-13 17:40 Robot·H 阅读(95) | 评论 (0)编辑

三十而立

     摘要: 所想~。。。~  阅读全文

posted @ 2008-04-13 17:25 Robot·H 阅读(188) | 评论 (3)编辑

xml_xlst_javascript_test

     摘要: xml_xlst_javascript_test.rar  阅读全文

posted @ 2008-04-13 15:00 Robot·H 阅读(115) | 评论 (0)编辑

readonly vs. const [C#]

     摘要: readonly vs. const [C#] Written by Allen Lee   阅读全文

posted @ 2008-04-08 15:56 Robot·H 阅读(35) | 评论 (0)编辑

迭代得错误。。

     摘要: usingSystem;usingSystem.Collections;usingSystem.Collections.Generic;publicclassStack<T>:IEnumerable<T>{//数组,索引T[]items;intidx;publicStack(){idx=0;items=newT[10];}publicvoidPush(Tt){items[i... 阅读全文

posted @ 2008-04-06 21:47 Robot·H 阅读(63) | 评论 (2)编辑

探讨技术、享受人生

     摘要: 王者之盟CSharp队
群号:32097134
探讨技术、享受人生
  阅读全文

posted @ 2008-04-03 14:29 Robot·H 阅读(103) | 评论 (0)编辑

心迹

     摘要: 疾病和命运的参悟。  阅读全文

posted @ 2008-04-01 15:48 Robot·H 阅读(111) |