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

📄 owcreport.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 PrintReport() 
{
	window.focus() 
	window.print();
}
function window_onload() 
{
	window.parent.RightHead.btnPrint.disabled =false;
}
//-->
</script>
<%
	
	dim WExcel
	set WExcel=server.CreateObject("WExcel.Report")
	
	dim CurItems,MultiSelectItems,SearchValues,strWhere,strWhereDesc,strOrderBy,FromSearch
	dim SheetID,ReportID
	dim ClientWidth,ClientHeight
	dim ReportType,ReportStatus,ReportHead,ListData
	SheetID=Request.Cookies("Report")("SheetID")
	ReportID=Request.Cookies("Report")("ReportID" & SheetID)
	dim Exist
	Exist=WExcel.ReportExist(cint(UserID),cint(SheetID),cint(ReportID))
	CheckErr
	if Exist=false then
		Response.Redirect "/hcgis/notfound.asp?Name=报表&Depth=0"
	end if
	
	dim Result
	
	strOrderBy=""
	if instr(1,Request.ServerVariables("HTTP_REFERER"),"search.asp")>0 then
		'来自于查询操作
		FromSearch=1
		strWhere=""
		strWhereDesc=""
		CurItems=Request.Form("CurItems")
		MultiSelectItems=Request.Form("MultiSelectItems")
		if CurItems<>"" then
			WExcel.GetSQLWhere cint(SheetID),cstr(CurItems),cstr(MultiSelectItems),strWhere,strWhereDesc,SearchValues
		end if
		ClientWidth=Request.Form("ClientWidth")
		ClientHeight=Request.Form("ClientHeight")
		Response.Cookies("Report")("ClientWidth")=ClientWidth
		Response.Cookies("Report")("ClientHeight")=ClientHeight
		Response.Cookies("Report")("Where")=strWhere
		Result=WExcel.GetOWCReport(cint(UserID),cint(SheetID),cint(ReportID),cint(FromSearch),cstr(strWhere),cstr(strWhereDesc),cstr(strOrderBy),cint(ClientWidth),cint(ClientHeight),ReportType,ReportStatus,ReportHead,ListData)
		Response.Cookies("Report").Expires = CookieLife
	else
		'来自于刷新操作
		FromSearch=0
		strWhereDesc=""
		strWhere=Request.Cookies("Report")("Where")
		ClientWidth=Request.Cookies("Report")("ClientWidth")
		ClientHeight=Request.Cookies("Report")("ClientHeight")
		Result=WExcel.GetOWCReport(cint(UserID),cint(SheetID),cint(ReportID),cint(FromSearch),cstr(strWhere),cstr(strWhereDesc),cstr(strOrderBy),cint(ClientWidth),cint(ClientHeight),ReportType,ReportStatus,ReportHead,ListData)
	end if
	CheckErr
%>
<html>
	<head>
	</head>
	<body leftmargin="0" topmargin="0" marginwidth="0" marginheight="0" LANGUAGE="javascript" onload="return window_onload()">
    <table width=95% align=center border=0 CELLSPACING=0 CELLPADDING=0>
			<TR height=45>
				<TD>
					<b><FONT size=3><%=ReportHead%></FONT></b>
				</TD>
			</TR>
			<%if ReportStatus<>1 then%>
				<TR height=230 valign="center">
					<TD>
						有人正在修改报表规格,尚未完成,暂不能访问。
					</TD>
				</TR>
			<%else%>
				<%if Result<>0 then%>
						<TR height=230 valign="center">
							<TD>
								报表生成失败。
							</TD>
						</TR>
				<%else%>
					<%if ubound(ListData)>0 then%>
						<TR>
							<TD>
							<%if cint(ReportType)=ReportType_Analyze then%>
								<TABLE width=100% border=0 CELLSPACING=1 CELLPADDING=0 bgcolor=999999>
							<%else%>
								<TABLE width=100% border=0 CELLSPACING=0 CELLPADDING=0>
							<%end if%>
							<%
									dim Count
									Count=ubound(ListData)
									for i=1 to Count
										Response.Write ListData(i-1)
									next
							%>
								</TABLE>
							</TD>
						</TR>
					<%else%>
						<TR height=230 valign="center">
							<TD>
								没有符合查询条件的数据。
							</TD>
						</TR>
					<%end if%>
				<%end if%>
			<%end if%>
			<TR>
				<TD>
					<HR>
				</TD>
			</TR>
			<TR>
				<TD>
			    <table width=100% border=0 CELLSPACING=0 CELLPADDING=0>
						<TR>
							<TD WIDTH=70%>
								<p align=LEFT>附查询条件:<%=server.HTMLEncode(strWhereDesc)%></p>
							</TD>
							<TD WIDTH=30%>
								<p align=RIGHT><%=cstr(now())%></p>
							</TD>
						</TR>
					</TABLE>
				</TD>
			</TR>
		</TABLE>
	</body>                                                                                                           
</html>

⌨️ 快捷键说明

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