using System;
using System.Drawing;
using System.Windows.Forms;

namespace _12_4
{
    public partial class Form1 : Form
    {
        public Form1()
        {
            InitializeComponent();
        }

        public static Bitmap VLine(int x, int y1, int y2, Color color)
        {
            Bitmap image = new Bitmap(250, 250);
            int count;
            for (count = y1; count <= y2; count++)
                image.SetPixel(x, count, color);
            return image;
        }

        private void button1_Click(object sender, EventArgs e)
        {
            pictureBox1.Image = VLine(50, 50, 200, Color.Black);
        }
    }
}