Dim cn As New ADODB.Connection
Dim rs As New ADODB.Recordset
Dim cSQL As String
Dim suma As Double
Dim fini As String
Dim ffin As String
fini = InputBox("Fecha inicial")
ffin = InputBox("Fecha final")
& " and reg.id_empresa <> art.id_proveedor " _
& " and art.id_proveedor = 10 " _
& " [title] and reg.fecha between #" + fini + "# and #" + ffin + "# " _
& " ORDER BY reg.fecha"