hi,
I have made a rectangle on my windows form using Rectangle Class.
Problem is that its width is 200 and height is 100.
I only want to fill the 4th part of rectangle means 50px out of total width 200px with brown colour.
System.Drawing.SolidBrush myBrush = new System.Drawing.SolidBrush(Color.Brown);
Rectangle rec = new Rectangle(0, 0, 200, 100);
System.Drawing.Graphics formGraphics = this.CreateGraphics();
formGraphics.FillRectangle(myBrush, rec);
Any help will be highly appericated
Thanks
Loading

Kunal VaishyaRank #990 · 2K reputationPosted Jul 24, 2013, 12:40 AM EDT
ayesha ahmad6 reputationPosted Jul 24, 2013, 2:16 AM EDT
VulpesRank #55 · 29.2K reputationPosted Jul 24, 2013, 2:41 AM EDT
ayesha ahmad6 reputationPosted Jul 24, 2013, 4:09 AM EDT
Iftikar HussainRank #423 · 5.9K reputationPosted Jul 24, 2013, 4:25 AM EDT
Try like this
borderStyle,borderColor,borderWidth,borderStyle,borderColor,borderWidth,borderStyle,
borderColor,borderWidth,borderStyle);
Regards,
Iftikar
VulpesRank #55 · 29.2K reputationPosted Jul 24, 2013, 4:32 AM EDT