MS Access DSN Less Connection Example

Here is the example code for dsn less ms access connection.

<%
Set db = Server.CreateObject("ADODB.Connection")
db.Open "Provider=Microsoft.Jet.OLEDB.4.0; Data Source=" & Server.MapPath("database.mdb") & ";"

db.execute("INSERT INTO MyTable VALUES ('Dan Hendricks', 22)")
set rs=db.execute("SELECT * FROM MyTable")

rs.MoveFirst
Do Until rs.EOF
Response.Write rs("NAME") & "<br>"
rs.MoveNext
Loop
rs.Close
%>

  • 0 Users Found This Useful
Was this answer helpful?

Related Articles

Internal clients cannot use Internet Explorer to access FTP sites

SYMPTOMS When you use Microsoft Internet Explorer to try to access a File Transfer Protocol...

Creating application/virtual Directory in HELM

By default all \wwwroot folders are already configured as application directories. This allows...

CDOSYS Sample Email Code

<% Dim ObjSendMail Dim iConf Dim Flds   Set ObjSendMail =...

Uploading / Updating Microsoft SQL Server DataBase

1 : Upload your local database files [ LDF & MDF ] any where in WWW folder. Theses database...

SQL Server Connection String

string str = 'server=localhost;database=dbname;uid=dbuser;pwd=dbpass;'; dbname : Your Database...

Powered by WHMCompleteSolution