请教ASP高手(急!!)对象关闭时,不允许操作
<!--#includefile="../include/ADOVBS.asp"--><!--#includefile="../include/keepHouse.asp...
<!--#include file="../include/ADOVBS.asp"-->
<!--#include file="../include/keepHouse.asp"-->
<!--#include file="../include/header.asp"-->
<head>
<link href="../include/WebCourseSettlementStyle.Css" rel="stylesheet" type="text/css">
<%
dim SETTING_ID
dim CLASSROOM_ID
dim DAY_TIME
dim Collision
dim ARRANGE_ID
SETTING_ID=request("SETTING_ID")
CLASSROOM_ID=session("CLASSROOM_ID")
if CLASSROOM_ID="" then
showmsg("您没有选择教室。")
end if
session("CLASSROOM_ID")=""
DAY_TIME=request("DAY")&request("TIME")
if SETTING_ID="" or CLASSROOM_ID="" or DAY_TIME="" then
call trigErr()
end if
set Comd=server.createobject("ADODB.Command")
call openDB()
set Comd.ActiveConnection=conn
Comd.CommandType=adCMdStoredProc
Comd.CommandText="DetectArrangeCollision"
set Para1=Comd.CreateParameter("SETTING_ID",adInteger,adParamInput,4)
set Para2=Comd.CreateParameter("CLASSROOM_ID",adInteger,adParamInput,4)
set Para3=Comd.CreateParameter("DAY_TIME",adVarChar,adParamInput,20)
Comd.Parameters.Append Para1
Comd.Parameters.Append Para2
Comd.Parameters.Append Para3
Comd("SETTING_ID") = SETTING_ID
Comd("CLASSROOM_ID") = CLASSROOM_ID
Comd("DAY_TIME") = DAY_TIME
rs.open Comd
if not rs.eof then-------(出错行!)
response.write "<table width='764' border=1 cellspacing=0 "
response.write "cellpadding=0 bgcolor=#99CCFF align=center "
response.write "bordercolordark=#FFFFFF bordercolorlight=#0000dd > "
response.write "<tr><td> "
response.write "该操作引起冲突:"
response.write "</td></tr></table>"
'sql="select * from VIEW_Arrange where ARRANGE_ID="&ARRANGE_ID
'rs.open sql,conn,1,1
%>
请教请教!
能不能说的得具体点,if not rs.eof then(出错行!)前哪里rs被关闭了,我用了rs.open Comd ,为什么不能打开,应该如何打开,最好直接说明如何修改程序,谢谢! 展开
<!--#include file="../include/keepHouse.asp"-->
<!--#include file="../include/header.asp"-->
<head>
<link href="../include/WebCourseSettlementStyle.Css" rel="stylesheet" type="text/css">
<%
dim SETTING_ID
dim CLASSROOM_ID
dim DAY_TIME
dim Collision
dim ARRANGE_ID
SETTING_ID=request("SETTING_ID")
CLASSROOM_ID=session("CLASSROOM_ID")
if CLASSROOM_ID="" then
showmsg("您没有选择教室。")
end if
session("CLASSROOM_ID")=""
DAY_TIME=request("DAY")&request("TIME")
if SETTING_ID="" or CLASSROOM_ID="" or DAY_TIME="" then
call trigErr()
end if
set Comd=server.createobject("ADODB.Command")
call openDB()
set Comd.ActiveConnection=conn
Comd.CommandType=adCMdStoredProc
Comd.CommandText="DetectArrangeCollision"
set Para1=Comd.CreateParameter("SETTING_ID",adInteger,adParamInput,4)
set Para2=Comd.CreateParameter("CLASSROOM_ID",adInteger,adParamInput,4)
set Para3=Comd.CreateParameter("DAY_TIME",adVarChar,adParamInput,20)
Comd.Parameters.Append Para1
Comd.Parameters.Append Para2
Comd.Parameters.Append Para3
Comd("SETTING_ID") = SETTING_ID
Comd("CLASSROOM_ID") = CLASSROOM_ID
Comd("DAY_TIME") = DAY_TIME
rs.open Comd
if not rs.eof then-------(出错行!)
response.write "<table width='764' border=1 cellspacing=0 "
response.write "cellpadding=0 bgcolor=#99CCFF align=center "
response.write "bordercolordark=#FFFFFF bordercolorlight=#0000dd > "
response.write "<tr><td> "
response.write "该操作引起冲突:"
response.write "</td></tr></table>"
'sql="select * from VIEW_Arrange where ARRANGE_ID="&ARRANGE_ID
'rs.open sql,conn,1,1
%>
请教请教!
能不能说的得具体点,if not rs.eof then(出错行!)前哪里rs被关闭了,我用了rs.open Comd ,为什么不能打开,应该如何打开,最好直接说明如何修改程序,谢谢! 展开
2个回答
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询