Forum de discussion
Forum « Programmation ASP » (archives)
erreur de code ds le 1er post
Envoyé: 16 septembre 2003, 5h10 par veuxa
<%
DBPath = Server.MapPath("/soirees/soirees.mdb") : DBPwd = "opel"
ConnectString = "driver={Microsoft Access Driver (*.mdb)};dbq=" & DBPath & ";pwd=" & DBPwd
Set DBs = Server.CreateObject("ADODB.Connection")
Set RSs = server.CreateObject("ADODB.Recordset")
DBs.Open ConnectString
'---------------------------------------------------------
sub ouvreSO(requete)
RSs.open "select " & requete,DBs,2,2,&H0001
end sub
sub execSO(requete)
set SO = Server.CreateObject("ADODB.Command")
----------->SO.ActiveConnection = ConnectString <---- c la ligne ou c censé planté....
SO.CommandText = requete
SO.CommandType = 1
SO.CommandTimeout = 0
SO.Prepared = true
SO.Execute()
end sub
%>
Réponses
|