Quantcast
Channel: Windows Forms General forum
Viewing all articles
Browse latest Browse all 12583

Draw a line on the bottom of a panel

$
0
0

Hi,

I tried to draw a line on the bottom of a panel. 

The beginning point must be started from left bottom corner to the right bottom corner.

I have searched on this site and tried it myself but no luck:

This is what I have:

        private void panel1_Paint(object sender, PaintEventArgs e)
        {
            Color yourColor1 = Color.FromArgb(194, 196, 203);
            Pen yourPen1 = new Pen(yourColor1, 1);
            e.Graphics.DrawLine(yourPen1, 0, 0, 0, panel1.ClientRectangle.Height - 1);
        }

Who can help me?

Thank you in advanced,

Greetings,

Peter Kiers


Viewing all articles
Browse latest Browse all 12583

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>