ifrupdateid.asp

来自「绿叶oa系统办公自动化 2008.工作日志管理,文件管理」· ASP 代码 · 共 56 行

ASP
56
字号
<%@LANGUAGE="VBSCRIPT"%>
<!--#include file="../../../Connections/oavbsconn.asp" -->
<%
Dim r__u
r__u = "1"
If (Session("userssdfgfhtrh") <> "") Then 
  r__u = Session("userssdfgfhtrh")
End If
%>
<%
Dim r
Dim r_numRows

Set r = Server.CreateObject("ADODB.Recordset")
r.ActiveConnection = MM_oavbsconn_STRING
r.Source = "SELECT top 1 id as maxid  FROM infoall  WHERE 信息属性 = '通知' and 发送人帐号='" + Replace(r__u, "'", "''") + "'  order by id desc"
r.CursorType = 0
r.CursorLocation = 2
r.LockType = 1
r.Open()
r_numRows = 0
%>
<%if not r.eof or not r.bof then
dim maxid
 maxid=r("maxid")
end if%>
<%
Dim Recordset1__MMColParam
Recordset1__MMColParam = "1"
If (Session("userssdfgfhtrh")   <> "") Then 
  Recordset1__MMColParam = Session("userssdfgfhtrh")  
End If
%>
<%
Dim Recordset1
Dim Recordset1_numRows
Set Recordset1 = Server.CreateObject("ADODB.Recordset")
Recordset1.ActiveConnection = MM_oavbsconn_STRING
Recordset1.Source = "SELECT 通知编号  FROM 通知附件db  WHERE 发送人帐号 = '" + Replace(Recordset1__MMColParam, "'", "''") + "' and 通知编号=0"
Recordset1.CursorType = 0
Recordset1.CursorLocation = 2
Recordset1.LockType = 3
Recordset1.Open()
Recordset1("通知编号")=maxid
Recordset1.update
Recordset1_numRows = 0
%>
<%
Recordset1.Close()
Set Recordset1 = Nothing
%>
<%
r.Close()
Set r = Nothing
%>

⌨️ 快捷键说明

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