
04/02/2005, 19:18
|
| | Fecha de Ingreso: abril-2004
Mensajes: 70
Antigüedad: 21 años, 3 meses Puntos: 0 | |
Este es el codigo del botón facturar del formulario de Facturación. Este Boton es el que hace que se abra el data report y luego aparece el error
que mencione antes
Private Sub Facturar_Click()
Dim sql As String
Dim agregaR As String
Dim dbs As Database
Dim rst As Recordset
Dim x As Integer
For x = 1 To 1000
agregaR = "insert into [facturacion] values (" & Val(Grid.TextMatrix(x, 1)) & ", " & Val(Grid.TextMatrix(x, 2)) & ", '" & Grid.TextMatrix(x, 4) & "', " & Val(Grid.TextMatrix(x, 6)) & ", ' " & TxtTotal.text & " ',' " & Label8.Caption & " ' ,' " & Label9.Caption & " ',' " & Label11.Caption & " ',' " & Label10.Caption & " ',' " & Label12.Caption & " ', " & Val(facturanum.text) & ", '" & Label15.Caption & "',' " & Label14.Caption & " ')"
On Error GoTo eze
CNN.Execute (agregaR)
Next x
nfactura = facturanum
eze:
If Option1 = True Then ‘ inicia el formulario de carga de datos de los clientes que pagan con tarjeta de credito
frmTarjetas.Show
Else
Report1.Show
End If
Gracias por la ayuda |