Programacion Vb

Páginas: 3 (596 palabras) Publicado: 23 de junio de 2012
Imports System.Data.SqlClient 'MANDAMOS A IMPORTAR LA CLASE
Public Class clientes 'VARIABLE PUBLICA
Public cn As New SqlConnection 'CREAMOS UNA NUEVA CONECCION
Public var As New validar'INSTANCIA QUE ASE REFERENCIA A LA CLASE
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
Me.Hide() 'ESCONDE EL FORMULARIOcuenta.Show() 'MANDA A LLAMAR EL FORMULARIO O LO PRESENTA EN PANTALLA
End Sub

Private Sub TextBox2_KeyPress(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyPressEventArgs)Handles txtnombre.KeyPress
Me.txtidentidad.Text = StrConv(Me.txtidentidad.Text, VbStrConv.Uppercase) 'CONVIERTE TODOS LOS TEXTOS A MAYUSCULAS
Me.txtidentidad.SelectionStart =Len(Me.txtidentidad.Text)
e.Handled = var.Nombre(e.KeyChar, Me.txtidentidad.Text, Me.txtidentidad.SelectionStart)
End Sub
Private Sub TextBox1_KeyPress(ByVal sender As Object, ByVal e AsSystem.Windows.Forms.KeyPressEventArgs) Handles txtidentidad.KeyPress
If (Asc(e.KeyChar)) >= 48 And (Asc(e.KeyChar)) <= 57 Or (Asc(e.KeyChar)) = System.Windows.Forms.Keys.Back Thene.Handled = False 'VALIDAR QUE SOLO ENTREN NUMEROS
Else
e.Handled = True
End If
End Sub

Private Sub TextBox3_KeyPress(ByVal sender As Object, ByVale As System.Windows.Forms.KeyPressEventArgs) Handles txtnumero.KeyPress
If (Asc(e.KeyChar)) >= 48 And (Asc(e.KeyChar)) <= 57 Or (Asc(e.KeyChar)) = System.Windows.Forms.Keys.Back Thene.Handled = False 'VALIDAR QUE SOLO ENTREN NUMEROS
Else
e.Handled = True
End If
End Sub

Private Sub TextBox1_TextChanged(ByVal sender AsSystem.Object, ByVal e As System.EventArgs) Handles txtidentidad.TextChanged

End Sub

Private Sub Button4_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button4.Click...
Leer documento completo

Regístrate para leer el documento completo.

Estos documentos también te pueden resultar útiles

  • programacion vb y carta gantt
  • Programación En Botones Para Vb
  • Programacion en vb
  • Programacion Vb
  • funciones de programación vb
  • Programacion en vb con c#
  • curso de iniciacion a la programacion en vb
  • Introduccion a la programacion VB .NET

Conviértase en miembro formal de Buenas Tareas

INSCRÍBETE - ES GRATIS