日期:2010-02-06 浏览次数:21203 次
Sub DeleteObject(ByRef obj)
Set obj = nothing
obj = null
End Sub
Class CDB
private m_oConn, m_oRS
private m_pageIndex, m_pageSize, m_pageCount, m_recordCount
private strError
private m_QueryString
private Sub Class_Initialize()
m_oConn = null
m_oRS = null
m_pageIndex = 1
m_pageSize = 10
m_pageCount = 1
m_recordCount = 0
Call connect()
End Sub
private property Get GetConnectionString()
if InStr(LCase(Request.ServerVariables("SCRIPT_NAME")), "/admin/") > 0 then
GetConnectionString = "Provider=microsoft.jet.oledb.4.0;data source=" & Server.MapPath("DataBase\data.mdb")
else
GetConnectionString = "Provider=microsoft.jet.oledb.4.0;data source=" & Server.MapPath("Admin\DataBase\data.mdb")
end if
end property
public property Let SetPageSize(num)
if Not isNumeric(num) then Exit property
num = CInt(num)
if num > 0 Then m_pageSize = num
End property
'object.AppendSearch(paraName) = paraValue
public property Let AppendQueryString(paraName, paraValue)
m_QueryString = m_QueryString & "&" & paraName & "=" & Server.URLEncode(paraValue)
end property
public property Let SetPageIndex(num)
&nb