⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 list.asp

📁 学生档案与成绩管理(1)学生档案管理:记录每个学生的档案信息
💻 ASP
字号:
<!-- #include file = "../../include/asphead.asp" -->
<!-- #include file = "../../include/function.asp" -->
<%CheckUser()%>
<link href="../../include/main.css" rel="stylesheet" type="text/css">
<script src="../../include/function.js" type="text/javascript"></script>
<script ID="clientEventHandlersJS" LANGUAGE="javascript">
<!--

function View(RowID) {
	if(window.showModalDialog ("frame.asp?Target=edit.asp?RowID=" + RowID,"","dialogwidth:550px;dialogheight:327px;Status:0;center:1;resizable=1;")==true)
	{
		window.navigate("list.asp");
	}
}

function window_onload() {
	window.parent.RightHead.frmData.CurPage.value=CurPage.value;
	window.parent.RightHead.PageNavigate.innerHTML=PageNavigate.value;
	window.parent.RightHead.chkAll.status=false;
	if(CurPage.value>0)
	{
		window.parent.RightHead.btnDel.disabled =false;
		parent.RightPanel.rows=parent.RightHead.RightHeadTable.clientHeight + ",*";
	}
	else
	{
		window.parent.RightHead.btnDel.disabled =true;
		parent.RightPanel.rows=parent.RightHead.RightHeadTable.clientHeight + ",*";
	}
}

//-->
</script>
<%
	
	dim WExcel
	set WExcel=server.CreateObject("WExcel.Sheet")
	
	dim CurItems,strWhere,strWhereDesc,strOrderBy,FromSearch
	dim CurPage,NoField,PageCount,RecordCount,CurFromRecord,CurToRecord,PageNavigate,RowIDs,CanDeleteRowIDs,SummaryLine
	dim SheetID,StatusID
	dim MemoList
	dim FirstAddRowID
	dim AddMode

	SheetID=MemoSheet_ID
	if instr(1,Request.ServerVariables("HTTP_REFERER"),"listhead.asp")>0 then
		if Trim(Request.Form("Search"))="1" then
			'来自于查询操作
			if isnumeric(Request.Form("MemoStatus")) then
				StatusID=Request.Form("MemoStatus")
			else
				StatusID=0
			end if
			Response.Cookies("MyFold")("StatusID")=StatusID
			Response.Cookies("MyFold").Expires = CookieLife
			FromSearch=1
			AddMode=0
			strWhere=""
			strWhereDesc=""
			WExcel.GetMemoSQLWhere cint(UserID),cint(StatusID),strWhere,strWhereDesc
			Response.Cookies("Temp")("Where" & SheetID)=strWhere
			strOrderBy=Request.Cookies("Sheet")("OrderBy" & CoID & "-" & SheetID)
			CurPage=1
			WExcel.GetMemoList cint(UserID),cint(FromSearch),cint(AddMode),cstr(strWhere),cstr(strWhereDesc),strOrderBy,CurPage,NoField,PageCount,RecordCount,CurFromRecord,CurToRecord,PageNavigate,RowIDs,CanDeleteRowIDs,SummaryLine,MemoList
			Response.Cookies("Temp")("CurPage" & SheetID)=CurPage
			Response.Cookies("Temp")("AddMode" & SheetID)="0"
			Response.Cookies("Temp")("FirstAddRowID" & SheetID)=""
		else
			'来自于排序、翻页操作
			FromSearch=0
			AddMode=0
			strWhere=Request.Cookies("Temp")("Where" & SheetID)
			strOrderBy=Request.Form("OrderBy")
			CurPage=Request.Form("CurPage")
			if Request.Cookies("Temp")("AddMode" & SheetID)="1" then
				AddMode=1
				WExcel.GetMemoList cint(UserID),cint(FromSearch),cint(AddMode),cstr(strWhere),cstr(""),strOrderBy,CurPage,NoField,PageCount,RecordCount,CurFromRecord,CurToRecord,PageNavigate,RowIDs,CanDeleteRowIDs,SummaryLine,MemoList
			else
				FromSearch=0
				AddMode=0
				strWhereDesc=""
				WExcel.GetMemoList cint(UserID),cint(FromSearch),cint(AddMode),cstr(strWhere),cstr(strWhereDesc),strOrderBy,CurPage,NoField,PageCount,RecordCount,CurFromRecord,CurToRecord,PageNavigate,RowIDs,CanDeleteRowIDs,SummaryLine,MemoList
			end if
			Response.Cookies("Temp")("CurPage" & SheetID)=CurPage
			Response.Cookies("Sheet")("OrderBy" & CoID & "-" & SheetID)=strOrderBy
			Response.Cookies("Sheet").Expires = CookieLife
		end if
	else
		if Trim(Request.QueryString("MemoStatusForSearch"))<>"" then
			'最初进入此页面时,来自于listhead 的 navigate
			if isnumeric(Request.QueryString("MemoStatusForSearch")) then
				StatusID=Request.QueryString("MemoStatusForSearch")
			else
				StatusID=0
			end if
			Response.Cookies("MyFold")("StatusID")=StatusID
			Response.Cookies("MyFold").Expires = CookieLife
			FromSearch=0	'不作为真正的查询动作,不需记log
			AddMode=0
			strWhere=""
			strWhereDesc=""
			WExcel.GetMemoSQLWhere cint(UserID),cint(StatusID),strWhere,strWhereDesc
			Response.Cookies("Temp")("Where" & SheetID)=strWhere
			strOrderBy=Request.Cookies("Sheet")("OrderBy" & CoID & "-" & SheetID)
			CurPage=1
			WExcel.GetMemoList cint(UserID),cint(FromSearch),cint(AddMode),cstr(strWhere),cstr(strWhereDesc),strOrderBy,CurPage,NoField,PageCount,RecordCount,CurFromRecord,CurToRecord,PageNavigate,RowIDs,CanDeleteRowIDs,SummaryLine,MemoList
			Response.Cookies("Temp")("CurPage" & SheetID)=CurPage
			Response.Cookies("Temp")("AddMode" & SheetID)=AddMode
			Response.Cookies("Temp")("FirstAddRowID" & SheetID)=""
		else
			'来自于录入、删除、修改、视图设置、视图切换、导入、复制、批量修改操作,来自于自动查询
			FromSearch=0
			if Request.Cookies("Temp")("AddMode" & SheetID)="1" then
				AddMode=1
				FirstAddRowID=Request.Cookies("Temp")("FirstAddRowID" & SheetID)
				strWhere = "Fld" & RowID_ID & ">=" & FirstAddRowID & " and Fld" & CreaterID_ID & "=" & UserID
				Response.Cookies("Temp")("Where" & SheetID)=strWhere
				strOrderBy=Request.Cookies("Sheet")("OrderBy" & CoID & "-" & SheetID)
				WExcel.GetMemoList cint(UserID),cint(FromSearch),cint(AddMode),cstr(strWhere),cstr(""),strOrderBy,CurPage,NoField,PageCount,RecordCount,CurFromRecord,CurToRecord,PageNavigate,RowIDs,CanDeleteRowIDs,SummaryLine,MemoList
			else
				AddMode=0
				strWhereDesc=""
				strWhere=Request.Cookies("Temp")("Where" & SheetID)
				strOrderBy=Request.Cookies("Sheet")("OrderBy" & CoID & "-" & SheetID)
				CurPage=Request.Cookies("Temp")("CurPage" & SheetID)
				WExcel.GetMemoList cint(UserID),cint(FromSearch),cint(AddMode),cstr(strWhere),cstr(strWhereDesc),strOrderBy,CurPage,NoField,PageCount,RecordCount,CurFromRecord,CurToRecord,PageNavigate,RowIDs,CanDeleteRowIDs,SummaryLine,MemoList
			end if
		end if
	end if
	CheckErr
	dim Count
%>
<html>
	<head>
		<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
	</head>
	<body leftmargin="0" topmargin="0" marginwidth="0" marginheight="0" LANGUAGE="javascript" onload="return window_onload()">
		<%Count=ubound(MemoList)%>
		<%if RecordCount<=0 and AddMode=0 then%>
			<table width=100%>
				<TR height=230 valign="center">
					<TD align=center>
						没有该状态的备忘事项。
					</TD>
				</TR>
			</table>
		<%else%>
			<table width=100% cellspacing=1 bgcolor=999999>
				<%for i=1 to Count:Response.Write MemoList(i-1):next%>
			</table>
		<%end if%>
			<table width=100% border=0>
				<TR height=30 align=bottom>
					<TD>
						说明:备忘事项是您的私有信息,只有您自己可查看、维护,其他任何人无权访问。
					</TD>
				</TR>
			</table>
		<input TYPE="hidden" NAME="RecordCount" value="<%=RecordCount%>">
		<input TYPE="hidden" NAME="CurPage" value="<%=CurPage%>">
		<input TYPE="hidden" NAME="NoField" value="<%=NoField%>">
		<input TYPE="hidden" NAME="PageNavigate" value="<%=PageNavigate%>">
		<input TYPE="hidden" NAME="RowIDs" value="<%Count=ubound(RowIDs):for i=1 to Count:IF i=1 then Response.Write RowIDs(i-1) else Response.Write "," & RowIDs(i-1):end if:next%>">
		<input TYPE="hidden" NAME="CanDeleteRowIDs" value="<%Count=ubound(CanDeleteRowIDs):for i=1 to Count:IF i=1 then Response.Write CanDeleteRowIDs(i-1) else Response.Write "," & CanDeleteRowIDs(i-1):end if:next%>">
	</body>                                                                                                           
</html>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -