error de compilacion
Publicado por guido (15 intervenciones) el 06/02/2009 07:50:04
Cree un loguin con una base de datos creada por mi, al loguin entro, despues cree un formulario para agergar ususarios ami base de datos y pasa esto:
Error en compilacion
prosedimientos sub o function no definida y me salta aca:
Sub limpiar()
txtId.Text = ""
txtPASS.Text = ""
txtNOMBRE.Text = ""
txtApellido.Text = ""
txtDIRECCION.Text = ""
txtTELEFONO.Text = ""
DTPFECHA.Value = Date
txtId.SetFocus
End Sub
>>> Private Sub CDMCrear_Click()<<< aca me salta
If txtId = "" Then smgbox "El campo ID no pude quedar vacio", vbInformation, "Aviso": txtId.SetFocus: Exit Sub
If txtPASS = "" Then smgbox "El campo Contraceña del usuario no pude quedar vacio", vbInformation, "Aviso": txtPASS.SetFocus: Exit Sub
If txtNOMBRE = "" Then smgbox "El campo Nombre no pude quedar vacio", vbInformation, "Aviso": txtNOMBRE.SetFocus: Exit Sub
If txtApellido = "" Then smgbox "El campo Apellido no pude quedar vacio", vbInformation, "Aviso": txtApellido.SetFocus: Exit Sub
If txtDIRECCION = "" Then smgbox "El campo Direccion no pude quedar vacio", vbInformation, "Aviso": txtId.SetFocus: Exit Sub
If txtTELEFONO = "" Then smgbox "El campo Telefono no pude quedar vacio", vbInformation, "Aviso": txtTELEFONO.SetFocus: Exit Sub
With RsUsuarios
.Requery
.AddNew
!ID = txtId.Text
!NOMBRES = txtNOMBRES.Text
!Apellidos = txtApellidos.Text
!Direccion = txtDIRECCION.Text
!TELEFONO = txtTELEFONO.Text
!FECHA = DTPFECHA.Value
.Update
.Requery
limpiar
End With
End Sub
Private Sub Form_Load()
usuarios
Set GrillaUsuarios.DataSource = RsUsuarios
End Sub
Error en compilacion
prosedimientos sub o function no definida y me salta aca:
Sub limpiar()
txtId.Text = ""
txtPASS.Text = ""
txtNOMBRE.Text = ""
txtApellido.Text = ""
txtDIRECCION.Text = ""
txtTELEFONO.Text = ""
DTPFECHA.Value = Date
txtId.SetFocus
End Sub
>>> Private Sub CDMCrear_Click()<<< aca me salta
If txtId = "" Then smgbox "El campo ID no pude quedar vacio", vbInformation, "Aviso": txtId.SetFocus: Exit Sub
If txtPASS = "" Then smgbox "El campo Contraceña del usuario no pude quedar vacio", vbInformation, "Aviso": txtPASS.SetFocus: Exit Sub
If txtNOMBRE = "" Then smgbox "El campo Nombre no pude quedar vacio", vbInformation, "Aviso": txtNOMBRE.SetFocus: Exit Sub
If txtApellido = "" Then smgbox "El campo Apellido no pude quedar vacio", vbInformation, "Aviso": txtApellido.SetFocus: Exit Sub
If txtDIRECCION = "" Then smgbox "El campo Direccion no pude quedar vacio", vbInformation, "Aviso": txtId.SetFocus: Exit Sub
If txtTELEFONO = "" Then smgbox "El campo Telefono no pude quedar vacio", vbInformation, "Aviso": txtTELEFONO.SetFocus: Exit Sub
With RsUsuarios
.Requery
.AddNew
!ID = txtId.Text
!NOMBRES = txtNOMBRES.Text
!Apellidos = txtApellidos.Text
!Direccion = txtDIRECCION.Text
!TELEFONO = txtTELEFONO.Text
!FECHA = DTPFECHA.Value
.Update
.Requery
limpiar
End With
End Sub
Private Sub Form_Load()
usuarios
Set GrillaUsuarios.DataSource = RsUsuarios
End Sub
Valora esta pregunta


0