unction ExecuteReader(connString,cmdText)
Dim objConn,objRS
Set objConn = Server.CreateObject("ADODB.Connection")
objConn.Open connString
Set objRS = objConn.Execute(cmdText)
Set ExecuteReader = objRS
End Function
''/// <summary>
''/// 执行Recordset
''/// </summary>
''/// <param name="connString">连接字符</param>
''/// <param name="cmdText">sql命令</param>
''/// <returns>RS</returns>
Public Function Recordset(connString,cmdText)
Dim objConn,objRS
Set objConn = Server.CreateObject("ADODB.Connection")
objConn.Open connString
Set objRS = Server.CreateObject("ADODB.RecordSet")
objRS.Open cmdText,objConn,1,3
Set Recordset = objRS
End Function
Private Sub Class_Initialize()
CONN_STRING = "provider = microsoft.jet.oledb.4.0;data source=" & Server.Mappath("db.mdb")
End Sub
End Class
%>