![Antiguo](http://static.forosdelweb.com/fdwtheme/images/statusicon/post_old.gif)
31/01/2003, 11:16
|
![Avatar de vamp_02](http://static.forosdelweb.com/customavatars/avatar16625_1.gif) | | | Fecha de Ingreso: febrero-2002 Ubicación: Santiago de Chile
Mensajes: 367
Antigüedad: 23 años Puntos: 0 | |
no me resulto, podrias decrime en que vaya esta cosa....
<HTML>
<script runat="server">
Sub addusu_click(obj As object, e As eventargs)
if ispostback() then
Dim objConn As New OleDbConnection ("Provider=MSDAORA.1;Password=clcabrer;User ID=clcabrer;Data Source=ccabrera")
Dim sSQL, Resul as string
sSQL = "Insert into usu (USUARIO,PASSWORD) values ('" & login.text & "','" & password.text & "')"
Dim objCmd As New OleDbCommand (sSQL, objConn)
objConn.open
try
'Aqui escribes el codigo que PUEDE producir error
resul= objCmd.ExecuteNonQuery
message.show("Registro Insertado")
Catch
'Aqui lo que quieres mostrar al ocurrir el error.
message.show("se produjo un error")
Finally
'Aqui pones lo que siempre se ejecutara no importando si hubo o no un error
conexion.close
End if
End sub
</script>
Gracias |