Ver Mensaje Individual
  #10 (permalink)  
Antiguo 12/05/2011, 15:56
guillebomtrasmiti
 
Fecha de Ingreso: noviembre-2010
Ubicación: madrid
Mensajes: 478
Antigüedad: 13 años, 5 meses
Puntos: 5
Respuesta: update no adminte comas

Public Sub remplazaProducto()
'Try
Dim adapt As New OleDbDataAdapter
Dim setda As New DataSet
Dim com = conexion.CreateCommand

com.CommandType = CommandType.Text
com.CommandText = "UPDATE IntroduccionDeVentasAhora SET Producto = (" & TextRemplazar.Text & ") where Producto = (" & TextBuscar.Text & ") and NombreFormaPago <> ('TARJETA CREDITO')and Fecha BETWEEN @FI AND @FF"

com.Parameters.AddWithValue("@FI", Fecha1.Value.Date.ToString("dd/MM/yyyy"))
com.Parameters.AddWithValue("@FF", Fecha2.Value.Date.ToString("dd/MM/yyyy"))

adapt.UpdateCommand = com
conexion.Open()
CStr(com.ExecuteScalar()).ToString()
conexion.Close()
'Catch
MessageBox.Show("Los productos no pueden contener comas P,dr...etc")
'End Try
End Sub

ahora quiero cambiar el nombre del producto y me pone este error al ejecutar;
no se han especificado valores para algunos de los parametros requeridos...sabeis pro qué?=