<% 'Dimension variables Dim adoCon 'Holds the Database Connection Object Dim rs 'Holds the recordset for the record to be updated Dim strSQL 'Holds the SQL query for the database
ID = Request.QueryString("id")
'Create an ADO connection odject Set adoCon = Server.CreateObject("ADODB.Connection")
'Set an active connection to the Connection object using a DSN-less connection adoCon.Open "DRIVER={Microsoft Access Driver (*.mdb)}; DBQ=" & Server.MapPath("../../databaser/news.mdb")
'Create an ADO recordset object Set rs = Server.CreateObject("ADODB.Recordset")
'Initialise the strSQL variable with an SQL statement to query the database strSQL = "SELECT * FROM nyheder WHERE news_id="&ID response.write strsql 'Open the recordset with the SQL query rs.Open strSQL, adoCon
'Reset server objects rs.Close Set rs = Nothing Set adoCon = Nothing
Tilladte BB-code-tags: [b]fed[/b] [i]kursiv[/i] [u]understreget[/u] Web- og emailadresser omdannes automatisk til links. Der sættes "nofollow" på alle links.