| 漳州網(wǎng)站建設(shè)|友客來|百城千站|漳州網(wǎng)絡(luò)公司 | 登錄 注冊(cè) 控制中心 新聞中心 客戶支持 交費(fèi)方式 聯(lián)系我們 |
| ASP連接access數(shù)據(jù)庫例程
| ||
| 注意:要運(yùn)行上述ACCESS例程請(qǐng)先下載數(shù)據(jù)庫,放在db 或 rwdata文件夾下。請(qǐng)將例程放在根目錄下。 <% Dim mode mode=request.form("text4") if mode=1 then name=request.form("text1") age=request.form("text2") addr=request.form("text3") if not isnumeric(age) then response.write "age must be number!try again":response.end age=clng(age) end if '******************************************************************** ' 與AccessDB相關(guān)的連接信息 ' 可以參照它建立您的數(shù)據(jù)庫連接 '******************************************************************** Dim conn,rs,dbpath Set conn=Server.CreateObject("ADODB.Connection") Set rs=Server.CreateObject("ADODB.RecordSet") dbpath=Server.MapPath("rwdata/db_test_com.mdb") conn.Open "Driver={Microsoft Access Driver (*.mdb)}; DBQ="&dbpath '******************************************************************** '******************************************************************** dim strsql
if mode=1 then '******************************************************************** | ||
|
注意:要運(yùn)行上述ACCESS例程請(qǐng)先下載數(shù)據(jù)庫,放在rwdata文件夾下。請(qǐng)將例程放在根目錄下。 |
閩公網(wǎng)安備 35060202000035號(hào)