高分悬赏:网站制作高手请进,有关于网站程序/源代码的问题
是一个关于网站购物系统的代码问题:在购买的最后一步出现错误:如下:MicrosoftJETDatabaseEngine错误'80040e09'没有使用'orders'对象...
是一个关于网站购物系统的代码问题:
在购买的最后一步出现错误:如下:
Microsoft JET Database Engine 错误 '80040e09'
没有使用 'orders' 对象的必要权限。请让系统管理员或安装此对象的人为您设置适当的权限。
/payment3.asp,行 68
下面为payment3.asp的部分代码:
Set cmdTemp = Server.CreateObject("ADODB.Command")
Set InsertCursor = Server.CreateObject("ADODB.Recordset")
cmdTemp.CommandText = "SELECT top 1 * FROM orders order by id desc"
cmdTemp.CommandType = 1
Set cmdTemp.ActiveConnection = conn
InsertCursor.Open cmdTemp, , 3, 3
InsertCursor.addnew
if session("memberID")<>"" then
InsertCursor("memberID") =session("memberID")
else
InsertCursor("memberID") ="·??á?±"
end if
InsertCursor("customerName") =Request("customerName")
InsertCursor("address") =Request("address")
InsertCursor("code") =Request("code")
InsertCursor("phone") =Request("phone")
InsertCursor("email") =Request("email")
InsertCursor("payment") =Request("payment")
InsertCursor("remark") =Request("remark")
InsertCursor("fUserId") =session("crgw")
InsertCursor("refererID") =session("refererID")
InsertCursor.update
InsertCursor.close
sql="select top 1 * from orders order by id desc"
'set rs=conn.execute (sql)
set rs = server.createobject("adodb.recordset")
rs.open sql,conn,1,1
if rs.eof or err then
response.write "êy?Y?a2ù×÷꧰ü£???<a href='Javascript:window.history.go(-1)'>·μ??</a>"
response.End
else
orderID=rs("id")
end if
'response.write rs("id")&"rsid<br>"
'response.write InsertCursor("id")&"rsid<br>"
set InsertCursor=nothing
' response.write session("quantityList")&"quantityList<br>"
' response.write session("productList")&"productList<br>"
productList=session("productList")
If Len(productList) <>0 Then
quantityArray = Split(session("quantityList"), ", ")
productArray = Split(session("productList"), ", ")
for i=0 to UBound(productArray)
set rs=server.createobject("adodb.recordset")
sql = "Select * From product where id="&productArray(i)
rs.open sql,conn,1,1
if Not rs.EOF or err then
quantity = quantityArray(i)
' quantity = cstr(quantityArray(i))
' response.write quantity&"quantity"
' response.End
If quantity <= 0 Then quantity = 1
sql = "INSERT INTO orderDetail (orderID, productID, productName, price,quantity) "
sql = sql & "VALUES( "& orderID & ","
sql = sql & productArray(i) &",'"
sql = sql & rs("name")& "','"
sql = sql & rs("memberPrice")& "',"
sql = sql & quantity&")"
' response.write sql
Conn.Execute(sql)
sql="update product set buyNum=buyNum+1 where id="&productArray(i)
conn.execute (sql)
给予解决方案的回答再加50分!
我的QQ:543206765 急得我头痛,望有网友有支招 展开
在购买的最后一步出现错误:如下:
Microsoft JET Database Engine 错误 '80040e09'
没有使用 'orders' 对象的必要权限。请让系统管理员或安装此对象的人为您设置适当的权限。
/payment3.asp,行 68
下面为payment3.asp的部分代码:
Set cmdTemp = Server.CreateObject("ADODB.Command")
Set InsertCursor = Server.CreateObject("ADODB.Recordset")
cmdTemp.CommandText = "SELECT top 1 * FROM orders order by id desc"
cmdTemp.CommandType = 1
Set cmdTemp.ActiveConnection = conn
InsertCursor.Open cmdTemp, , 3, 3
InsertCursor.addnew
if session("memberID")<>"" then
InsertCursor("memberID") =session("memberID")
else
InsertCursor("memberID") ="·??á?±"
end if
InsertCursor("customerName") =Request("customerName")
InsertCursor("address") =Request("address")
InsertCursor("code") =Request("code")
InsertCursor("phone") =Request("phone")
InsertCursor("email") =Request("email")
InsertCursor("payment") =Request("payment")
InsertCursor("remark") =Request("remark")
InsertCursor("fUserId") =session("crgw")
InsertCursor("refererID") =session("refererID")
InsertCursor.update
InsertCursor.close
sql="select top 1 * from orders order by id desc"
'set rs=conn.execute (sql)
set rs = server.createobject("adodb.recordset")
rs.open sql,conn,1,1
if rs.eof or err then
response.write "êy?Y?a2ù×÷꧰ü£???<a href='Javascript:window.history.go(-1)'>·μ??</a>"
response.End
else
orderID=rs("id")
end if
'response.write rs("id")&"rsid<br>"
'response.write InsertCursor("id")&"rsid<br>"
set InsertCursor=nothing
' response.write session("quantityList")&"quantityList<br>"
' response.write session("productList")&"productList<br>"
productList=session("productList")
If Len(productList) <>0 Then
quantityArray = Split(session("quantityList"), ", ")
productArray = Split(session("productList"), ", ")
for i=0 to UBound(productArray)
set rs=server.createobject("adodb.recordset")
sql = "Select * From product where id="&productArray(i)
rs.open sql,conn,1,1
if Not rs.EOF or err then
quantity = quantityArray(i)
' quantity = cstr(quantityArray(i))
' response.write quantity&"quantity"
' response.End
If quantity <= 0 Then quantity = 1
sql = "INSERT INTO orderDetail (orderID, productID, productName, price,quantity) "
sql = sql & "VALUES( "& orderID & ","
sql = sql & productArray(i) &",'"
sql = sql & rs("name")& "','"
sql = sql & rs("memberPrice")& "',"
sql = sql & quantity&")"
' response.write sql
Conn.Execute(sql)
sql="update product set buyNum=buyNum+1 where id="&productArray(i)
conn.execute (sql)
给予解决方案的回答再加50分!
我的QQ:543206765 急得我头痛,望有网友有支招 展开
1个回答
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询