\' Session(\"DSN\") kan placeres i global.asa. \' Så er den altid tilgængelig fra ens sider. Session(\"DSN\") = \"DRIVER={Microsoft Access Driver (*.mdb)}; UID=admin; PWD=; DBQ=\" & Server.MapPath(\"/db/database.mdb\")
Dim rsConnect Dim strSQL
Set rsConnect = Server.CreateObject(\"ADODB.Recordset\") strSQL = \"SELECT * FROM [table] ORDER BY id DESC;\" rsConnect.Open strSQL, Session(\"DSN\"), 3, 3 If Not rsConnect.EOF Then Response.Write \"<TABLE BORDER=\'1\' CELLPADDING=\'0\' CELLSPACING=\'0\' WIDTH=\'250\'>\" & vbCrLf Response.Write \" <TR><TD COLSPAN=\'2\'>\" & rsConnect(\"prduktet\") & \"</TD></TR>\" & vbCrLf Response.Write \" <TR>\" & vbCrLf Response.Write \" <TD ROWSPAN=\'2\' WIDTH=\'100\' HEIGHT=\'100\'>\" & rsConnect(\"billed\") & \"</TD>\" & vbCrLf Response.Write \" <TD>\" & rsConnect(\"Pris\") & \"</TD>\" & vbCrLf Response.Write \" </TR>\" & vbCrLf Response.Write \" <TR><TD>\" & rsConnect(\"Specifikationer\") & \"</TD></TR>\" & vbCrLf Response.Write \"</TABLE>\" & vbCrLf End If rsConnect.Close Set rsConnect = 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.