Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Imports Oracle.DataAccess.Client
- Imports SIMULADOR_DAO
- Public Class Registrar
- Inherits System.Web.UI.Page
- Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
- End Sub
- Protected Sub btnRegistrar_Click(sender As Object, e As EventArgs) Handles btnRegistrar.Click
- Dim clRegistrar As New SIMULADOR_LOG.clsExamenLOG
- Dim User As New SIMULADOR_ENT.clsUsuarioSim
- With User
- .dni_user = txtDNI.Text
- .ape_pat_user = txtApellidoPaterno.Text
- .ape_mat_user = txtApellidoMaterno.Text
- .nombre_user = txtNombres.Text
- .direccion_user = txtDireccion.Text
- .celular_user = txtCelular.Text
- .correo_user = txtCorreo.Text
- '.ubigeo =
- .fech_nacimiento = txtFechaNacimiento.Text
- End With
- Dim mensajeLog As String = clRegistrar.RegistrarUsuario(User)
- Dim Mensaje As String = "<script type=""text/javascript"">" &
- "Message('El sistema dice: " & mensajeLog & "')</script>"
- ClientScript.RegisterStartupScript(Me.GetType, "msg", Mensaje)
- End Sub
- Protected Sub cmbDepartamento_SelectedIndexChanged(sender As Object, e As EventArgs) Handles cmbDepartamento.SelectedIndexChanged
- End Sub
- Protected Sub cmbProvincia_SelectedIndexChanged(sender As Object, e As EventArgs) Handles cmbProvincia.SelectedIndexChanged
- End Sub
- Protected Sub cmbDistrito_SelectedIndexChanged(sender As Object, e As EventArgs) Handles cmbDistrito.SelectedIndexChanged
- End Sub
- Function Consultar(strSQL As String) As DataSet
- Dim strConn As String = "User Id=WEB;Password=1Ytop6;Data Source=DES;Pooling=False"
- Dim conexion As New OracleConnection(strConn)
- Dim cmd As New OracleCommand("SELECT DISTINCT dpto FROM up100.UBIGEO;", conexion)
- cmd.CommandType = CommandType.Text
- conexion.Open()
- Dim oda As New OracleDataAdapter(cmd)
- Dim ds As New DataSet
- oda.Fill(ds)
- conexion.Close()
- Return ds
- End Function
- End Class
Add Comment
Please, Sign In to add comment