% ' Declare our variables... always good practice! Dim cnnSimple ' ADO connection Dim rstSimple ' ADO recordset Dim strDBPath ' path to our Access database (*.mdb) file ' MapPath of virtual database file path to a physical path. ' If you want you could hard code a physical path here. strDBPath = Server.MapPath("cmppdata\cmpp.mdb") ' Create an ADO Connection to connect to the scratch database. ' We're using OLE DB but you could just as easily use ODBC or a DSN. Set cnnSimple = Server.CreateObject("ADODB.Connection") ' This line is for the Access sample database: cnnSimple.Open "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & strDBPath & ";" ' Execute a query using the connection object. Set rstSeminar = cnnSimple.Execute("SELECT * FROM tblSeminars ORDER BY SeminarID;") %>
![]() |
Cellular and MolecularPharmacology and Physiology |
|||||||||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
|
|||||||||||||||||||||||||||||||||||||||||||||||