VS 2013 一直说 "String" 未定义,我不确定它有什么问题
VS 2013 keeps saying that "String" is undefined, i'm not sure whats wrong with it
我不太确定字符串未定义是什么意思,我已经尝试 google 但出现的只是关于字符串的随机内容。
#include "MyForm.h"
#include "String"
using namespace System::Windows::Forms;
[STAThread]
int main(cli::array<String^>^ args)
{
Application::EnableVisualStyles();
Application::SetCompatibleTextRenderingDefault(false);
Organizer1::MyForm form;
Application::Run(%form);
}
Class String
在命名空间 System
中定义
所以要么写
using namespace System;
或使用限定名称
int main(cli::array<System::String^>^ args)
^^^^^^^^^^^^
我不太确定字符串未定义是什么意思,我已经尝试 google 但出现的只是关于字符串的随机内容。
#include "MyForm.h"
#include "String"
using namespace System::Windows::Forms;
[STAThread]
int main(cli::array<String^>^ args)
{
Application::EnableVisualStyles();
Application::SetCompatibleTextRenderingDefault(false);
Organizer1::MyForm form;
Application::Run(%form);
}
Class String
在命名空间 System
所以要么写
using namespace System;
或使用限定名称
int main(cli::array<System::String^>^ args)
^^^^^^^^^^^^