query with parameters and asp

From: Marcelo Marchesoni (mmarches_at_adinet.com.uy)
Date: 03/22/04


Date: Mon, 22 Mar 2004 19:15:36 -0300

I try to get the next query with parameters.
I can't pass the parameters values.

<%@ Language=VBScript %>
<%
cnnPath = server.mapPath("../fpdb/" & session("base_cliente"))
cnnPath = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & cnnPath &
";Persist Security Info=False"

Set conexion = Server.CreateObject("ADODB.Connection")
   conexion.CursorLocation=2
   conexion.Open cnnPath
Set rst_saldos=Server.CreateObject("ADODB.Recordset")
Set rst_sal= Server.CreateObject("ADODB.Command")
with rst_sal
     .ActiveConnection = conexion
     .CommandText="ResultadosPeriodo"
     .CommandType=2

HERE IS THE PROBLEM!!!!!

     ' .CreateParameter ("fechainicial",adDate)
  ' .CreateParameter ("fechafinal",adDate,1)
' .Parameters("fechainicial").Value=Request.Form("fechainicial")
' .Parameters("fechafinal").Value=Request.QueryString("fechafinal")
    ' rst_saldos= .Execute
end with

saldos="Abre y cierra el recordset"
conexion.close
%>