English Deutsch Français Italiano Español Português 繁體中文 Bahasa Indonesia Tiếng Việt ภาษาไทย
All categories

How to connect and handle a access data base with asp???
from where i can get the sourece codes..?

2006-11-13 07:59:12 · 4 answers · asked by Anonymous in Computers & Internet Programming & Design

4 answers

For Some reason, it will not display the code correctly. Email me and I will send it to you, unless this is enough.

OK, did this once before, then I abandoned it for PHP and MySQL. Here was my code:

dim objConn
Set objConn =
Server.CreateObject("ADODB.Connection")
objConn.ConnectionString="Driver={Microsoft Access Driver (*.mdb)};" & _
"DBQ=MyDatabase.mdb"

dim objRS
Set objRS = Server.CreateObject ("ADODB.Recordset")
objRS.Open "MyTable", objConn, , , adCmdTable

// Replace "MyDatabase.mdb" and "MyTable" with the Access Database name and the Table name.

the line that has ADODB Conn... should say
("ADODB.Connection")

Hope this helps.

2006-11-13 08:03:53 · answer #1 · answered by Kevin 4 · 0 0

Learnasp.com is your best bet for classic ASP programming.

2006-11-13 16:11:41 · answer #2 · answered by Kasey C 7 · 0 0

Bewteen vbscripts tags you would use ADO:


Dim cnAccess
Dim recAccess
Set recAccess = CreateObject("ADODB.recordset")
Set cnAccess = CreateObject("ADODB.connection")
cnAccess.Open "Driver= {Microsoft Access Driver (*.mdb)};DBQ=" & MDB_PATH & " ;"
Set recAccess = cnAccess.Execute("select count(*) from " & Table_Name & ";")

Hope this helps...

2006-11-15 17:13:45 · answer #3 · answered by Lee S 2 · 0 0

You can get examples of various ODBC and OLE-DB connection strings at http://www.connectionstrings.com

2006-11-13 16:52:52 · answer #4 · answered by Kryzchek 4 · 0 0

fedest.com, questions and answers