close
在之前Visual Studio 2010, 可以找到Windows Form應用程式
但是, 在新版Visual Stuio 2012竟然找不到!
在Visual Studio 2012 選擇CLR Empty Project
Project –> Add New Item
Click UI and select Windows Form
Myform UI will be created
Click WindowsForm2012
準備設定程式入口點<Entry Point>
程式入口點Entry Point輸入main
點選MyForm.cpp, 輸入下列程式碼
1: #include "MyForm.h"
2: using namespace System;
3: using namespace System::Windows::Forms;
4:
5:
6: void main( void )
7: {
8: WindowsForm2012::MyForm myForm;
9: Application::Run(%myForm);
10: }
編譯程式
全站熱搜