cad sunny

cad sunny

  • NA
  • 138
  • 22.9k

draw line between forms

Sep 29 2014 7:27 AM
hi,

i used panel1,panel2 on form2
for eg i have slected panel1 color is red
panel2 click event
System.Drawing.Graphics graphicsObj;
            graphicsObj = panel2.CreateGraphics();
            Pen graphPen = new Pen(panel1.BackColor, 15);
            graphicsObj.DrawLine(graphPen, 5, 10, 120, 10);
now if click on panel2 show draw line panel1 selected red color
this is ok,


but i want to show form2 panel2 drawline color (i.e red) to form1 datagridview column0 row0
plz help me the code?

Answers (3)