I can read the data of an Excel in a shared folder using a Recordset
with ADODB
; I can write that data in a local file, but in the form Range().Value
. I could not do it using a Update
with ADODB
.
This is my connection:
Dim cnCaja As ADODB.Connection
Set cnCaja = New ADODB.Connection
cnCaja.Open "Provider=Microsoft.ACE.OLEDB.12.0;" & _
"Data Source='" & esteLibro & "';" & _
"Extended Properties='Excel 12.0;HDR=Yes;ReadOnly=False';"
The idea is that it is something parameterized and with filters, but to simplify the problem:
consUpdate = "Update [Base$A3:T100000] set INVERSIONES = 10000"
And finally the part that should do something:
Dim rsCaja As ADODB.Recordset
Set rsCaja = New ADODB.Recordset
rsCaja.Open consUpdate, cnCaja, adOpenKeyset, adLockOptimistic
It does not give an error or say anything.
What is missing for the INVERSIONES
field to be filled with 10000?