嗨,我一直在从 yt vid 复制此代码并尝试运行它,但它一直说使用 using 命名空间时存在语法错误,并且前面的标记是错误的,我该怎么办,请帮忙。我也使用 Windows 11,如果这会增加问题
#include "MyForm.h"
using namespace System;
using namespace System::Windows::Forms;
[STAThreadAttribute]
int main(array<String^>^ args) {
Application::EnableVisualStyles();
Application::SetCompatibleTextRenderingDefault(false);
Project1::MyForm form;
Application::Run(% form);
}
正在运行的应用程序仅显示默认的空格式,但不显示我已应用的按钮,而我在此 GUI 项目中急需这些按钮