c# windows应用程序调用摄像头,为什么一直报错

问题遇到的现象和发生背景
问题相关代码,请勿粘贴截图

using System;
using AForge.Video.DirectShow;
using System.Windows.Forms;

namespace usbcamera1
{
public partial class Form1 : Form
{
private FilterInfoCollection videoDevices;//所有摄像设备
private VideoCaptureDevice videoDevice;//摄像设备
private void Form1_Load(object sender, EventArgs e)
{
videoDevices = new FilterInfoCollection(FilterCategory.VideoInputDevice);//得到所有接入的摄像设备
if (videoDevices.Count != 0)
{
foreach (FilterInfo device in videoDevices)
{
comboBox1.Items.Add(device.Name);//把摄像设备添加到摄像列表中
}
}
else
{
MessageBox.Show("没有找到摄像头!");
}
}
private void comboBox1_SelectedIndexChanged(object sender, EventArgs e)
{
videoDevice = new VideoCaptureDevice(videoDevices[comboBox1.SelectedIndex].MonikerString);
videoSourcePlayer1.VideoSource = videoDevice;
videoSourcePlayer1.SignalToStop();
videoSourcePlayer1.WaitForStop();
videoSourcePlayer1.Start();
}
private void button1_Click(object sender, EventArgs e)
{
videoSourcePlayer1.Stop();
videoSourcePlayer1.SignalToStop();
videoSourcePlayer1.WaitForStop();
}

}

}

运行结果及报错内容

严重性 代码 说明 项目 文件 行 禁止显示状态
错误 CS5001 程序不包含适合于入口点的静态 "Main" 方法 usbcamera1 C:\Users\Administrator\source\repos\usbcamera1\usbcamera1\CSC 1 活动的

我的解答思路和尝试过的方法

试了好多方法都不行,windows应用还要加main函数吗

我想要达到的结果

搞好了搞好了