If Not IsNumeric(txt1.Text) Then Cancel = True ElseIf CInt(txt1.Text) < 0 Then Cancel = True End If If Cancel Then MsgBox "Por favor, escriba un dato correcto", vbExclamation End If 'declarar las variables a comprobar Dim refproducto As Integer, desproducto As String 'extraer los valores de los controles textbox refproducto = CInt(Text1.Text) desproducto = CStr(Text2.Text) ' comprobar que son valores correctos If refproducto < 0 Or refproducto = Null Then GoTo manejador_error ' abrir el recordset indicando la tabla a la que queremos acceder rs.Open "INSERT INTO PRODUCTO (ID_PRODUCTO, DESCRIPCION_PRODUCTO) VALUES ( " & Text1.Text & ", '" & Text2.Text & "')", conn, adOpenDynamic, adLockOptimistic Exit Sub manejador_error: MsgBox "Por favor, introduzca valor correcto (5 cifras del código de tarifa + 2 cifras de la opción)", vbExclamation e-REdING. Biblioteca de la Escuela Superior de Ingenieros de Sevilla.


GESTIÓN Y OPTIMIZACIÓN DE LA PRODUCCIÓN EN UNA FÃBRICA DE ESTRUCTURAS METÃLICAS DE SILLERÃA

: Narbona Fernández, Jesús
: Ingeniería Organización
Contenido del proyecto: