Ver Mensaje Individual
  #3 (permalink)  
Antiguo 28/07/2011, 15:44
poeta3d
 
Fecha de Ingreso: diciembre-2010
Mensajes: 162
Antigüedad: 13 años, 5 meses
Puntos: 1
Respuesta: problema con codigo de visual c#

Cita:
Iniciado por HaverRamirez Ver Mensaje
talvez es porque tiene s el ++ en lugar del --
probe esto
int x;
private void numericUpDown2_ValueChanged(object sender, EventArgs e)
{


if (numericUpDown1.Value>0)
{

pictureBox1.Refresh();
pictureBox1.Update();
SolidBrush sa = new SolidBrush(Color.Black);
Graphics ga;
ga = pictureBox1.CreateGraphics();
ga.FillRectangle(sa, 400, 350, ++x, ++x);
ga.Dispose();
}
if (numericUpDown1.Value < 1000)
{

pictureBox1.Refresh();
pictureBox1.Update();
SolidBrush sa = new SolidBrush(Color.Black);
Graphics ga;
ga = pictureBox1.CreateGraphics();
ga.FillRectangle(sa, 400, 350, --x, --x);
ga.Dispose();
}

}

y no me lo agranda ni me lo achica el rectangulo y ya me perdi no se que esta mal