<%@language="vbscript" codepage="936"%>
<%session.codepage=936%>
<%
Response.Buffer=True
'''''''''''''''''''''''''''''' Access数据库 '''''''''''''''''''''''''''''''''''''''''''''''''''''''''
datapath    ="database/"      '数据库目录的相对路径
datafile    ="#@%tcbbs.asa"      '数据库的文件名
connstr="Provider=Microsoft.Jet.OLEDB.4.0;Data Source="&Server.MapPath(""&datapath&""&datafile&"")
'Connstr="DBQ="&server.mappath(""&datapath&""&datafile&"")&";DRIVER={Microsoft Access Driver (*.mdb)};"

SqlNowString="Now()"
SqlChar="'"
ver="2005 SP1"
'''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
On Error Resume Next
Set conn=Server.CreateObject("ADODB.Connection")
conn.open ConnStr
If Err Then
err.Clear
Set Conn = Nothing
Response.Write "数据库连接出错，请检查连接字串。"
Response.End
End If
On Error GoTo 0
%>