
RECORRER FORMULARIO CONTINUO
Publicado por Jose (40 intervenciones) el 04/12/2021 17:00:24
He de recorrer un formulario continuo para calcular los precios de venta de cada uno de los productos existentes.
Estoy utilizando esta rutina desde el evento: Despues de Actualizar y solo me calcula el primer producto existente.
No se donde pueda estar el error:
Dim rst As DAO.Recordset
Dim i As Integer
Set rst = Me.RecordsetClone
rst.MoveFirst
Do Until rst.EOF
For i = 1 To rst.RecordCount
DoCmd.OpenForm "MAESTRODEPRODUCTOSCABECERA", , , "IdProducto=" & IdProducto
Forms!MAESTRODEPRODUCTOSCABECERA!VER = "VERCOMBINADOS"
Forms!MAESTRODEPRODUCTOSCABECERA!Unidades = Me.UNIDADESTOTALES
rst.MoveNext
Next i
Loop
rst.Close
Set rst = Nothing
Os agradeceria si me pudieseis ayudar. Gracias
Estoy utilizando esta rutina desde el evento: Despues de Actualizar y solo me calcula el primer producto existente.
No se donde pueda estar el error:
Dim rst As DAO.Recordset
Dim i As Integer
Set rst = Me.RecordsetClone
rst.MoveFirst
Do Until rst.EOF
For i = 1 To rst.RecordCount
DoCmd.OpenForm "MAESTRODEPRODUCTOSCABECERA", , , "IdProducto=" & IdProducto
Forms!MAESTRODEPRODUCTOSCABECERA!VER = "VERCOMBINADOS"
Forms!MAESTRODEPRODUCTOSCABECERA!Unidades = Me.UNIDADESTOTALES
rst.MoveNext
Next i
Loop
rst.Close
Set rst = Nothing
Os agradeceria si me pudieseis ayudar. Gracias
Valora esta pregunta


0