摘要: 执行的类:publicclassAjaxMethod{[AjaxPro.AjaxMethod(AjaxPro.HttpSessionStateRequirement.Read)]publicDataSetGetDepartmentList(stringCorpCd){ChooseEmployeeDSTableAdapters.DepartmentsTableAdapteradapter=newChooseEmployeeDSTableAdapters.DepartmentsTableAdapter();ChooseEmployeeDS.DepartmentsDataTabletable=ada 阅读全文
posted @ 2011-09-08 09:26 茶海 阅读(420) 评论(0) 推荐(0) 编辑
摘要: 获取学生最高的分数信息select * from scores awherenot exists(select * from scoresb where and a.score>v_b.score and a.name=b.name) 阅读全文
posted @ 2011-08-29 10:56 茶海 阅读(657) 评论(0) 推荐(0) 编辑
摘要: protected void Page_Load(object sender, System.EventArgs e){... string[] maindir = stypes.Split(new char[] { ',' }); for (int i = 0; i < maindir.Length; i++) { lbclasss.Items.Add(new ListItem(maindir[i])); }...}//lbclasss.SelectedIndex 每次取值都为-1 protected void btntypedel_Click(object sende 阅读全文
posted @ 2011-08-24 11:18 茶海 阅读(864) 评论(0) 推荐(0) 编辑
摘要: <%@ Register TagPrefix="ajax" Namespace="MagicAjax.UI.Controls" Assembly="MagicAjax" %>... <ajax:AjaxPanel id="AjaxPanel2" runat="server"> <tr class="tdbg"> <td class="style1"> 企业所在地: </td> <td col 阅读全文
posted @ 2011-07-19 15:44 茶海 阅读(676) 评论(0) 推荐(0) 编辑
摘要: 1,设置IIS为可匿名访问和asp.net web.config中设置为form验证2,检索数据存储验证用户,并检索角色(如果不是基于角色可不用)3,使用FormsAuthenticationTicket创建一个Cookie并回发到客户端,并存储角色到票中,如:FormsAuthentication.SetAuthCookie(Username,true false)cookies保存时间:HttpContext.Current.Response.Cookies[FormsAuthentication.FormsCookieName].EXPires=DateTime.Now.AddDays( 阅读全文
posted @ 2011-07-14 16:37 茶海 阅读(849) 评论(0) 推荐(0) 编辑
摘要: 首先在asp.net创建两个WebForm页,分别命名为Default1,Default2。下面给出代码清单://Default1.aspx<%@ Page Language="C#" Debug="true" AutoEventWireup="true" CodeFile="Default1.aspx.cs" Inherits="Default1" %><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional 阅读全文
posted @ 2011-07-13 09:25 茶海 阅读(523) 评论(1) 推荐(0) 编辑
摘要: 用Job调度 作业的操作企业管理器 --管理 --SQL Server代理 --右键作业 --新建作业 --"常规"项中输入作业名称 --"步骤"项 --新建 --"步骤名"中输入步骤名 --"类型"中选择"Transact-SQL 脚本(TSQL)" --"数据库"选择执行命令的数据库 --"命令"中输入要执行的语句: EXEC 存储过程名 ... --该存储过程用于创建表 --确定 --"调度"项 --新建调度 --"名称 阅读全文
posted @ 2011-06-27 10:43 茶海 阅读(429) 评论(0) 推荐(0) 编辑
摘要: 第一种:<script language="javascript" type="text/javascript"> window.location.href="login.jsp?backurl="+window.location.href; </script>第二种:<script language="javascript">alert("返回");window.history.back(-1); </script>第三种: <script 阅读全文
posted @ 2011-06-18 10:27 茶海 阅读(259) 评论(0) 推荐(0) 编辑
摘要: <style type="text/css">#con{ border:5px solid #ccc;padding:10px;font-size:30px;}.a{ border:2px solid #ccc;background-color:#eee;}</style><div id="con"><!--外层容器--> <div class="a">111111</div> <div class="a" style="dis 阅读全文
posted @ 2011-06-02 16:22 茶海 阅读(2752) 评论(0) 推荐(0) 编辑
摘要: 1、DateTime 数字型 System.DateTime currentTime=new System.DateTime(); 1.1 取当前年月日时分秒 currentTime=System.DateTime.Now; 1.2 取当前年 int 年=currentTime.Year; 1.3 取当前月 int 月=currentTime.Month; 1.4 取当前日 int 日=currentTime.Day; 1.5 取当前时 int 时=currentTime.Hour; 1.6 取当前分 int 分=currentTime.Minute; 1.7 取当前秒 int 秒=curre 阅读全文
posted @ 2011-06-02 09:55 茶海 阅读(283) 评论(1) 推荐(1) 编辑