Your SlideShare is downloading. ×
Boton eliminar rosalia
Upcoming SlideShare
Loading in...5
×

Thanks for flagging this SlideShare!

Oops! An error has occurred.

×

Saving this for later?

Get the SlideShare app to save on your phone or tablet. Read anywhere, anytime - even offline.

Text the download link to your phone

Standard text messaging rates apply

Boton eliminar rosalia

29
views

Published on


0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total Views
29
On Slideshare
0
From Embeds
0
Number of Embeds
1
Actions
Shares
0
Downloads
0
Comments
0
Likes
0
Embeds 0
No embeds

Report content
Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
No notes for slide

Transcript

  • 1. Conalep Zacualpan Nombre: Rosalía Lara Santos Grupo: 606 Botones de Registro. IMPLEMENTACIÓN DE SISTEMAS DE INFORMACIÓN.
  • 2. CODIGO DE GRABAR If (DirectorioDataSet.haschange) Then Me.Validate() Me.registro.EndEdit() Me.RegistroTableAdapter.Update(Me.BaseCarpDataSet.registro) MsgBox("Grabando") IdTextBox.Enabled = False RFCTextBox.Enabled = False Nombre_de_la_empresaTextBox.Enabled = False DireccionTextBox.Enabled = False LocalidadTextBox.Enabled = False ProvinciaTextBox.Enabled = False Codigo_postalTextBox.Enabled = False TelefonoTextBox.Enabled = False Pagina_webTextBox.Enabled = False Codigo de eliminar Private Sub Button2_Click_2(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click Dim response As MsgBoxResult Dim MSG As String Dim TITULO As String Dim ESTILO As MsgBoxStyle Dim registroactual As DataRowView ESTILO = MsgBoxStyle.YesNo TITULO = "Eliminar los datos" MSG = " ¿Desesa que sean eliminados Los Datos?" Dim c1 As String Dim c2 As String Dim res As Boolean Dim bandera As Boolean bandera = True
  • 3. Dim SI As Integer SI = SI Dim tam As Integer tam = RegistroBindingSource.Count() RegistroBindingSource.MoveFirst() res = False c1 = RTrim(TextBox1.Text) c2 = RTrim(IdTextBox.Text) Do res = c2 Like c1 If (res = True) Then bandera = False Else RegistroBindingSource.MoveNext() c2 = RTrim(IdTextBox.Text) SI += 1 End If Loop While (bandera = True And SI <= tam) If (bandera = True) Then IdTextBox.Visible = False RFCTextBox.Visible = False Nombre_de_la_empresaTextBox.Visible = False DireccionTextBox.Visible = False LocalidadTextBox.Visible = False ProvinciaTextBox.Visible = False Codigo_postalTextBox.Visible = False TelefonoTextBox.Visible = False Pagina_webTextBox.Visible = False TextBox1.Text = "" TextBox1.Focus() MsgBox("Registro no encontrado") Else IdTextBox.Visible = True RFCTextBox.Visible = True Nombre_de_la_empresaTextBox.Visible = True DireccionTextBox.Visible = True LocalidadTextBox.Visible = True
  • 4. ProvinciaTextBox.Visible = True Codigo_postalTextBox.Visible = True TelefonoTextBox.Visible = True Pagina_webTextBox.Visible = True IdTextBox.Enabled = False RFCTextBox.Enabled = False Nombre_de_la_empresaTextBox.Enabled = False DireccionTextBox.Enabled = False LocalidadTextBox.Enabled = False ProvinciaTextBox.Enabled = False Codigo_postalTextBox.Enabled = False TelefonoTextBox.Enabled = False Pagina_webTextBox.Enabled = False TextBox1.Text = "" TextBox1.Focus() response = MsgBox(MSG, ESTILO, TITULO) If (response = MsgBoxResult.Yes) Then registroactual = RegistroBindingSource.Current registroactual.Row.Delete() '7Me.DatosTableAdapter.Update(Me.SipretDataSet.Datos) MsgBox("Registro eliminado") IdTextBox.Visible = False RFCTextBox.Visible = False Nombre_de_la_empresaTextBox.Visible = False DireccionTextBox.Visible = False LocalidadTextBox.Visible = False ProvinciaTextBox.Visible = False Codigo_postalTextBox.Visible = False TelefonoTextBox.Visible = False Pagina_webTextBox.Visible = False Else IdTextBox.Visible = False RFCTextBox.Visible = False Nombre_de_la_empresaTextBox.Visible = False DireccionTextBox.Visible = False
  • 5. LocalidadTextBox.Visible = False ProvinciaTextBox.Visible = False Codigo_postalTextBox.Visible = False TelefonoTextBox.Visible = False Pagina_webTextBox.Visible = False TextBox1.Text = "" TextBox1.Focus() MsgBox("El registro no se a eliminado") End If End Sub