摘要: (一)后台写JavaScript方式Response.Write("<script>widow.alert(\" " + this.Test1.text + "\")</script>" );(二)Button的OnClientClick 属性方式注:点取消则不执行服务器端的OnClick事件例:<asp: button OnClientClick="return c... 阅读全文
posted @ 2010-07-25 13:47 海乐学习 阅读(461) 评论(0) 推荐(0)
摘要: Microsoft SQL serverwindows安全登陆 "Data Source=(local); Initial Catalog=Northwind; Integrated Security=True;"SQL Server登陆"Data Source=(local); Initial Catalog=Northwind; UserID=sa; PassWord=111111;"Acce... 阅读全文
posted @ 2010-07-25 13:39 海乐学习 阅读(376) 评论(0) 推荐(0)
摘要: C#中委托与事件的基本使用方法://定义委托模板Public delegate void ReceiveMsgEventHandled(object sender,clsTcpMsgEventArgs e);//定义事件private event ReceiveMsgEventHandler ReceiveMsgEvent;//公有事件,注册事件Public event ReceiveMsgEve... 阅读全文
posted @ 2010-07-25 12:26 海乐学习 阅读(987) 评论(2) 推荐(0)
摘要: 在web开发经常会遇到如: &nbsp; 这样的字符。它其实是Html将一些特殊字符(Html语法字符)的一种表达方式。下面列举几个常用字符:&nbsp; 空格&amp; &&lt; <&gt; >&quot; "&qpos; ' 阅读全文
posted @ 2010-07-25 11:58 海乐学习 阅读(277376) 评论(6) 推荐(1)
摘要: 在网页中经常遇到要设置默认按钮,是在Html的form标签中设置。<form id="form1"defaultbutton="buttion1" //默认按钮 defaultfocut="test1" //默认焦点runat="server"> 阅读全文
posted @ 2010-07-25 11:46 海乐学习 阅读(890) 评论(0) 推荐(0)
摘要: Coolite中GridPanel自带的分页与GridView的分页一样,都是把所有数据全部读出放至内存中。本文使用数据库中储存过程的方式与GridPanel配合完成,每次访问仅读出分页的数据。前台: <ext:Store ID="Store1" OnRefreshData="Store1_RefershData" runat="server" AutoLoad="true"> <... 阅读全文
posted @ 2010-07-25 00:19 海乐学习 阅读(2168) 评论(2) 推荐(1)
摘要: 我在做弹出模态窗体时遇到了IE缓存问题。原因是更新后应得从数据库取新的数据,因为有缓存IE第二次以后便不回服务器了。所以取得的数据永远是第一次加载的数据,这是不行的。我的方法在Url地址上加随机数来避免缓存。javaScript 获取随机数方法如下:Math.floor(Math.random() * (n + 1));n为随机数的上限。如想取0~1000的随机数则:Math.floor(Math... 阅读全文
posted @ 2010-07-22 22:15 海乐学习 阅读(22973) 评论(0) 推荐(1)
摘要: FCKeditor 与 <base target="_self"/> 导至“无法打开Internet站点”错误问题:弹出模式窗口:"window.showModalDialog('KnowledgeEdit.aspx?Action=Edit&Text='+ '' + '','添加知识','dialogWidth:900px;dialogHeight:60... 阅读全文
posted @ 2010-07-22 17:04 海乐学习 阅读(378) 评论(0) 推荐(0)
摘要: javascript有两种数据类型的转换方法:(一)将整个值从一种类型转换为另一种数据类型(称作基本数据类型转换)(二)从一个值中提取另一种类型的值,并完成转换工作基本数据类型转换的三种方法:1.转换为字符型:String(); 例:String(678)的结果为"678"2.转换为数值型:Number(); 例:Number("678")的结果为6783.转换为布尔型:Boolean(); 例:... 阅读全文
posted @ 2010-07-19 15:54 海乐学习 阅读(329) 评论(0) 推荐(0)
摘要: Coolite 中的ComboBox控件示例,这里写出几个常用方法:一、基本用法:<ext:ComboBox ID="cboSelectCol" runat="server" AllowBlank="false" Editable="false"FieldLabel="检索条件" EmptyText="请选择检索条件" ><Items><ext:ListItem Te... 阅读全文
posted @ 2010-07-19 11:02 海乐学习 阅读(2167) 评论(0) 推荐(0)