private void btnAgregarProd_Click(object sender, RoutedEventArgs e)
 {
     if (cbxProducto.SelectedValue != null)
     {
         if (txtCantidad.Text.Trim().Length > 0)
         {
             int cantidad = 0;
             int.TryParse(txtCantidad.Text, out cantidad);
             if (cantidad > 0)
             {
                 int          _idProd      = int.Parse(cbxProducto.SelectedValue.ToString());
                 decimal      _preTot      = int.Parse(txtValorTotal.Text.ToString());
                 ProductosNEG productosNEG = new ProductosNEG();
                 var          datos        = productosNEG.CargarProducto(_idProd);
                 _EmitirPedido_AD.AgregarItemTablaProductos(_idProd, datos.NOMBRE, cantidad, Convert.ToDecimal(datos.PRECIO_COMPRA), _preTot);
                 Limpiar();
             }
             else
             {
                 txtCantidad.Text = "";
                 MessageBox.Show("Debe indicar una cantidad");
             }
         }
         else
         {
             MessageBox.Show("Debe indicar una cantidad");
         }
     }
     else
     {
         MessageBox.Show("Debe seleccionar un producto");
     }
 }