Index: /trunk/ab5.0/abdev/abdev/abdev.cpp
===================================================================
--- /trunk/ab5.0/abdev/abdev/abdev.cpp	(revision 499)
+++ /trunk/ab5.0/abdev/abdev/abdev.cpp	(revision 500)
@@ -88,23 +88,4 @@
 #endif
 
-
-void CreateProcessWithStdHandle( const std::string &appPath, const std::string &cmdLine)
-{
-	std::string argsStr = (std::string)"\"" + appPath + "\" " + cmdLine;
-	STARTUPINFO si;
-	PROCESS_INFORMATION pi;
-	memset(&si,0,sizeof(STARTUPINFO));
-	si.cb=sizeof(STARTUPINFO);
-	si.dwFlags = STARTF_USESTDHANDLES | STARTF_USESHOWWINDOW;
-	si.wShowWindow = SW_HIDE;
-	si.hStdOutput = GetStdHandle(STD_OUTPUT_HANDLE);
-	si.hStdInput = GetStdHandle(STD_INPUT_HANDLE);
-	si.hStdError = GetStdHandle(STD_ERROR_HANDLE);
-	
-	char args[8192];
-	lstrcpy( args, argsStr.c_str() );
-
-	CreateProcess( NULL, args, NULL, NULL, FALSE, NORMAL_PRIORITY_CLASS, NULL, NULL, &si, &pi );
-}
 
 void ToBigChar(char str[]){
@@ -1344,5 +1325,5 @@
 LRESULT CALLBACK WindowFunc(HWND hwnd,UINT message,WPARAM wParam,LPARAM lParam){
 	int i,i2,WndNum;
-	char str[MAX_PATH],temporary[1024],temp2[MAX_PATH],temp3[MAX_PATH],*pTemp;
+	char str[MAX_PATH],temporary[1024],temp2[MAX_PATH],*pTemp;
 	HWND hChild;
 	RECT rect;
@@ -1350,5 +1331,4 @@
 	HDROP hDrop;
 	HGLOBAL hGlobal;
-	HANDLE hFile;
 
 	static COLORREF colorUser=RGB(255,255,255);
@@ -1374,262 +1354,4 @@
 
 #ifndef THETEXT
-				case IDM_DEBUG:
-					if(pobj_Debugger->IsDebugging()){
-						pobj_Debugger->DebugContinue();
-						return 0;
-					}
-
-					hChild=GetWindow(hClient,GW_CHILD);
-					if(ProjectInfo.name[0]){
-						//プロジェクトが開かれている場合
-						if(!SetProjectToRun()) return 0;
-
-						//デバッグ用のコマンドライン及び実行可能ファイル（DLLのみ）
-						sprintf(temporary,"%s\r\n%s",ProjectInfo.szExePath,ProjectInfo.szCmdLine);
-						sprintf(temp2,"%spgm.tmp",pj_editor_Dir);
-						hFile=CreateFile(temp2,GENERIC_WRITE,0,NULL,CREATE_ALWAYS,FILE_ATTRIBUTE_ARCHIVE|FILE_ATTRIBUTE_HIDDEN|FILE_ATTRIBUTE_TEMPORARY,NULL);
-						DWORD dwAccessBytes;
-						WriteFile(hFile,temporary,lstrlen(temporary),&dwAccessBytes,NULL);
-						CloseHandle(hFile);
-
-						//ソースファイル名をtemp2へ
-						ProjectInfo.pobj_DBFileInfo->ppobj_FileInfo[0]->GetFullPath(temp2);
-
-						//出力ファイル名をtemp3へ
-						lstrcpy(temp3,ProjectInfo.lpszOutput_Debug);
-						GetFullPath(temp3,ProjectInfo.dir);
-
-						if(IsNeedCompileForProject(1))
-							sprintf(temporary,"\"%s\" \"%s\" /debug /run /wnd:%08x",temp2,temp3,hwnd);
-						else
-							sprintf(temporary,"\"%s\" \"%s\" /run /wnd:%08x",temp2,temp3,hwnd);
-
-						//DLLオプション
-						if(ProjectInfo.dwModuleType==MT_DLL) lstrcat(temporary," /dll");
-
-						//Unicodeオプション
-						if(ProjectInfo.dwOption & PJ_OP_UNICODE) lstrcat(temporary," /unicode");
-
-						//ブレークポイントをセーブ
-						ProjectInfo.pobj_DBBreakPoint->SaveToTempFile();
-					}
-					else{
-						//単独ソースコード
-						if(!SetRunning(hChild)) return 0;
-						if(IsNeedCompile(MdiInfo[GetWndNum(hChild)].path,1))
-							sprintf(temporary,"\"%s\" /debug /run /wnd:%08x",MdiInfo[GetWndNum(hChild)].path,hwnd);
-						else
-							sprintf(temporary,"\"%s\" /run /wnd:%08x",MdiInfo[GetWndNum(hChild)].path,hwnd);
-
-						//ブレークポイントをセーブ
-						pobj_DBBreakPoint->SaveToTempFile();
-					}
-
-					//コンパイルビューをクリップするかどうか
-					if(bClipCompileView){
-						lstrcat(temporary," /clip_compile_view");
-
-						//コンパイラビューを閉じる
-						if(hCompileView==(HWND)-1) return 0;
-						if(hCompileView){
-							hChild=hCompileView;
-							hCompileView=(HWND)-1;
-							SendMessage(hChild,WM_COMMAND,IDCANCEL,0);
-						}
-
-						//重複起動防止のため
-						hCompileView=(HWND)-1;
-					}
-
-					//インクルードディレクトリ
-					sprintf(temp2," /include_dir:\"%s\"",pobj_nv->GetIncludeDirFullPath().c_str());
-					lstrcat(temporary,temp2);
-
-					CreateProcessWithStdHandle( ActiveBasic::Common::Environment::GetCompilerExePath( selectingPlatform ), temporary );
-
-					return 0;
-				case IDM_DEBUGCOMPILE:
-					hChild=GetWindow(hClient,GW_CHILD);
-					if(ProjectInfo.name[0]){
-						//プロジェクトが開かれている場合
-						if(!SetProjectToRun()) return 0;
-
-						//ソースファイル名をtemp2へ
-						ProjectInfo.pobj_DBFileInfo->ppobj_FileInfo[0]->GetFullPath(temp2);
-
-						//出力ファイル名をtemp3へ
-						lstrcpy(temp3,ProjectInfo.lpszOutput_Debug);
-						GetFullPath(temp3,ProjectInfo.dir);
-
-						sprintf(temporary,"\"%s\" \"%s\" /debug /wnd:%08x",temp2,temp3,hwnd);
-
-						//DLLオプション
-						if(ProjectInfo.dwModuleType==MT_DLL) lstrcat(temporary," /dll");
-
-						//Unicodeオプション
-						if(ProjectInfo.dwOption & PJ_OP_UNICODE) lstrcat(temporary," /unicode");
-					}
-					else{
-						//単独ソースコード
-						if(!SetRunning(hChild)) return 0;
-						sprintf(temporary,"\"%s\" /debug /wnd:%08x",MdiInfo[GetWndNum(hChild)].path,hwnd);
-					}
-
-					//コンパイルビューをクリップするかどうか
-					if(bClipCompileView){
-						lstrcat(temporary," /clip_compile_view");
-
-						//コンパイラビューを閉じる
-						if(hCompileView==(HWND)-1) return 0;
-						if(hCompileView){
-							hChild=hCompileView;
-							hCompileView=(HWND)-1;
-							SendMessage(hChild,WM_COMMAND,IDCANCEL,0);
-						}
-
-						//重複起動防止のため
-						hCompileView=(HWND)-1;	
-					}
-
-					//インクルードディレクトリ
-					sprintf(temp2," /include_dir:\"%s\"",pobj_nv->GetIncludeDirFullPath().c_str());
-					lstrcat(temporary,temp2);
-
-					CreateProcessWithStdHandle( ActiveBasic::Common::Environment::GetCompilerExePath( selectingPlatform ), temporary );
-
-					return 0;
-				case IDM_ATTACH:
-					int idProcess;
-					DWORD dwPlatform;
-					idProcess=DialogBoxParam(hResInst,MAKEINTRESOURCE(IDD_ATTACH),hwnd,(DLGPROC)DlgAttach,(LPARAM)&dwPlatform);
-					if(idProcess==0) return 0;
-
-					sprintf(temporary,"/attach:%08x /wnd:%08x",idProcess,hwnd);
-
-					//コンパイルビューをクリップするかどうか
-					if(bClipCompileView){
-						lstrcat(temporary," /clip_compile_view");
-
-						//コンパイラビューを閉じる
-						if(hCompileView==(HWND)-1) return 0;
-						if(hCompileView){
-							hChild=hCompileView;
-							hCompileView=(HWND)-1;
-							SendMessage(hChild,WM_COMMAND,IDCANCEL,0);
-						}
-
-						//重複起動防止のため
-						hCompileView=(HWND)-1;
-					}
-
-					//インクルードディレクトリ
-					sprintf(temp2," /include_dir:\"%s\"",pobj_nv->GetIncludeDirFullPath().c_str());
-					lstrcat(temporary,temp2);
-
-					ActiveBasic::Common::Platform::EnumType platform;
-					if(dwPlatform==IMAGE_FILE_MACHINE_I386)
-					{
-						platform = ActiveBasic::Common::Platform::X86;
-					}
-					else if(dwPlatform==IMAGE_FILE_MACHINE_AMD64)
-					{
-						platform = ActiveBasic::Common::Platform::X64;
-					}
-					else
-					{
-						throw;
-					}
-
-					CreateProcessWithStdHandle( ActiveBasic::Common::Environment::GetCompilerExePath( platform ), temporary );
-
-					return 0;
-				case IDM_RELEASECOMPILE:
-					hChild=GetWindow(hClient,GW_CHILD);
-					if(ProjectInfo.name[0]){
-						//プロジェクトが開かれている場合
-						if(!SetProjectToRun()) return 0;
-
-						//ソースファイル名をtemp2へ
-						ProjectInfo.pobj_DBFileInfo->ppobj_FileInfo[0]->GetFullPath(temp2);
-
-						//出力ファイル名をtemp3へ
-						lstrcpy(temp3,ProjectInfo.lpszOutput_Release);
-						GetFullPath(temp3,ProjectInfo.dir);
-
-						sprintf(temporary,"\"%s\" \"%s\" /wnd:%08x",temp2,temp3,hwnd);
-
-						//DLLオプション
-						if(ProjectInfo.dwModuleType==MT_DLL) lstrcat(temporary," /dll");
-
-						//Unicodeオプション
-						if(ProjectInfo.dwOption & PJ_OP_UNICODE) lstrcat(temporary," /unicode");
-					}
-					else{
-						//単独ソースコード
-						if(!SetRunning(hChild)) return 0;
-						sprintf(temporary,"\"%s\" /wnd:%08x",MdiInfo[GetWndNum(hChild)].path,hwnd);
-					}
-
-					//コンパイルビューをクリップするかどうか
-					if(bClipCompileView){
-						lstrcat(temporary," /clip_compile_view");
-
-						//コンパイラビューを閉じる
-						if(hCompileView==(HWND)-1) return 0;
-						if(hCompileView){
-							hChild=hCompileView;
-							hCompileView=(HWND)-1;
-							SendMessage(hChild,WM_COMMAND,IDCANCEL,0);
-						}
-
-						//重複起動防止のため
-						hCompileView=(HWND)-1;
-					}
-
-					//インクルードディレクトリ
-					sprintf(temp2," /include_dir:\"%s\"",pobj_nv->GetIncludeDirFullPath().c_str());
-					lstrcat(temporary,temp2);
-
-					CreateProcessWithStdHandle( ActiveBasic::Common::Environment::GetCompilerExePath( selectingPlatform ), temporary );
-
-					return 0;
-				case IDM_RELEASERUN:
-					hChild=GetWindow(hClient,GW_CHILD);
-					if(ProjectInfo.name[0]){
-/*						//プロジェクトが開かれている場合
-						if(!SetProjectToRun()) return 0;
-
-						//必要であればリリースコンパイル
-						if(IsNeedCompileForProject(0))
-							SendMessage(hwnd,WM_COMMAND,IDM_RELEASECOMPILE,0);*/
-
-						if(ProjectInfo.dwModuleType==MT_DLL){
-							lstrcpy(temporary,ProjectInfo.szExePath);
-						}
-						else{
-							lstrcpy(temporary,ProjectInfo.lpszOutput_Debug);
-							GetFullPath(temporary,ProjectInfo.dir);
-						}
-					}
-					else{
-/*						//必要であればリリースコンパイル
-						if(!SetRunning(hChild)) return 0;
-
-						if(IsNeedCompile(MdiInfo[GetWndNum(hChild)].path,0))
-							SendMessage(hwnd,WM_COMMAND,IDM_RELEASECOMPILE,0);*/
-
-						//単独ソースコード
-						_splitpath(MdiInfo[GetWndNum(hChild)].path,temporary,temp2,temp3,NULL);
-						lstrcat(temporary,temp2);
-						lstrcat(temporary,temp3);
-						lstrcat(temporary,".exe");
-					}
-
-					//インクルードディレクトリ
-					sprintf(temp2," /include_dir:\"%s\"",pobj_nv->GetIncludeDirFullPath().c_str());
-					lstrcat(temporary,temp2);
-
-					ShellExecute(hwnd,"open",temporary,NULL,NULL,SW_SHOWNORMAL);
-					return 0;
 
 
Index: /trunk/ab5.0/abdev/abdev/include/MainFrame.h
===================================================================
--- /trunk/ab5.0/abdev/abdev/include/MainFrame.h	(revision 499)
+++ /trunk/ab5.0/abdev/abdev/include/MainFrame.h	(revision 500)
@@ -140,4 +140,19 @@
 	// 「オプション」メニューがクリックされた
 	void OnCmdSet( UINT uNotifyCode, int nID, CWindow wndCtl );
+
+	// 「デバッグ実行」メニューがクリックされた
+	void OnCmdDebug( UINT uNotifyCode, int nID, CWindow wndCtl );
+
+	// 「デバッグビルド」メニューがクリックされた
+	void OnCmdDebugCompile( UINT uNotifyCode, int nID, CWindow wndCtl );
+
+	// 「アタッチ」メニューがクリックされた
+	void OnCmdAttach( UINT uNotifyCode, int nID, CWindow wndCtl );
+
+	// 「リリースビルド」メニューがクリックされた
+	void OnCmdReleaseCompile( UINT uNotifyCode, int nID, CWindow wndCtl );
+
+	// 「リリース実行」メニューがクリックされた
+	void OnCmdReleaseRun( UINT uNotifyCode, int nID, CWindow wndCtl );
 
 private:
@@ -207,4 +222,9 @@
 #endif
 		COMMAND_ID_HANDLER_EX( IDM_SET, OnCmdSet )
+		COMMAND_ID_HANDLER_EX( IDM_DEBUG, OnCmdDebug )
+		COMMAND_ID_HANDLER_EX( IDM_DEBUGCOMPILE, OnCmdDebugCompile )
+		COMMAND_ID_HANDLER_EX( IDM_ATTACH, OnCmdAttach )
+		COMMAND_ID_HANDLER_EX( IDM_RELEASECOMPILE, OnCmdReleaseCompile )
+		COMMAND_ID_HANDLER_EX( IDM_RELEASERUN, OnCmdReleaseRun )
 	END_MSG_MAP()
 };
Index: /trunk/ab5.0/abdev/abdev/src/MainFrame.cpp
===================================================================
--- /trunk/ab5.0/abdev/abdev/src/MainFrame.cpp	(revision 499)
+++ /trunk/ab5.0/abdev/abdev/src/MainFrame.cpp	(revision 500)
@@ -746,2 +746,308 @@
 	DlgOptionSetting( m_hWnd );
 }
+
+void CreateProcessWithStdHandle( const std::string &appPath, const std::string &cmdLine)
+{
+	std::string argsStr = (std::string)"\"" + appPath + "\" " + cmdLine;
+	STARTUPINFO si;
+	PROCESS_INFORMATION pi;
+	memset(&si,0,sizeof(STARTUPINFO));
+	si.cb=sizeof(STARTUPINFO);
+	si.dwFlags = STARTF_USESTDHANDLES | STARTF_USESHOWWINDOW;
+	si.wShowWindow = SW_HIDE;
+	si.hStdOutput = GetStdHandle(STD_OUTPUT_HANDLE);
+	si.hStdInput = GetStdHandle(STD_INPUT_HANDLE);
+	si.hStdError = GetStdHandle(STD_ERROR_HANDLE);
+	
+	char args[8192];
+	lstrcpy( args, argsStr.c_str() );
+
+	CreateProcess( NULL, args, NULL, NULL, FALSE, NORMAL_PRIORITY_CLASS, NULL, NULL, &si, &pi );
+}
+
+void MainFrame::OnCmdDebug( UINT uNotifyCode, int nID, CWindow wndCtl )
+{
+	char temporary[1024], temp2[1024], temp3[1024];
+	if(pobj_Debugger->IsDebugging()){
+		pobj_Debugger->DebugContinue();
+		return;
+	}
+
+	HWND hChild = ::GetWindow(hClient,GW_CHILD);
+	if(ProjectInfo.name[0]){
+		//プロジェクトが開かれている場合
+		if(!SetProjectToRun()) return;
+
+		//デバッグ用のコマンドライン及び実行可能ファイル（DLLのみ）
+		sprintf(temporary,"%s\r\n%s",ProjectInfo.szExePath,ProjectInfo.szCmdLine);
+		sprintf(temp2,"%spgm.tmp",pj_editor_Dir);
+		HANDLE hFile=CreateFile(temp2,GENERIC_WRITE,0,NULL,CREATE_ALWAYS,FILE_ATTRIBUTE_ARCHIVE|FILE_ATTRIBUTE_HIDDEN|FILE_ATTRIBUTE_TEMPORARY,NULL);
+		DWORD dwAccessBytes;
+		WriteFile(hFile,temporary,lstrlen(temporary),&dwAccessBytes,NULL);
+		CloseHandle(hFile);
+
+		//ソースファイル名をtemp2へ
+		ProjectInfo.pobj_DBFileInfo->ppobj_FileInfo[0]->GetFullPath(temp2);
+
+		//出力ファイル名をtemp3へ
+		lstrcpy(temp3,ProjectInfo.lpszOutput_Debug);
+		GetFullPath(temp3,ProjectInfo.dir);
+
+		if(IsNeedCompileForProject(1))
+			sprintf(temporary,"\"%s\" \"%s\" /debug /run /wnd:%08x",temp2,temp3,m_hWnd);
+		else
+			sprintf(temporary,"\"%s\" \"%s\" /run /wnd:%08x",temp2,temp3,m_hWnd);
+
+		//DLLオプション
+		if(ProjectInfo.dwModuleType==MT_DLL) lstrcat(temporary," /dll");
+
+		//Unicodeオプション
+		if(ProjectInfo.dwOption & PJ_OP_UNICODE) lstrcat(temporary," /unicode");
+
+		//ブレークポイントをセーブ
+		ProjectInfo.pobj_DBBreakPoint->SaveToTempFile();
+	}
+	else{
+		//単独ソースコード
+		if(!SetRunning(hChild)) return;
+		if(IsNeedCompile(MdiInfo[GetWndNum(hChild)].path,1))
+			sprintf(temporary,"\"%s\" /debug /run /wnd:%08x",MdiInfo[GetWndNum(hChild)].path,m_hWnd);
+		else
+			sprintf(temporary,"\"%s\" /run /wnd:%08x",MdiInfo[GetWndNum(hChild)].path,m_hWnd);
+
+		//ブレークポイントをセーブ
+		extern CDBBreakPoint *pobj_DBBreakPoint;
+		pobj_DBBreakPoint->SaveToTempFile();
+	}
+
+	//コンパイルビューをクリップするかどうか
+	extern BOOL bClipCompileView;
+	if(bClipCompileView){
+		lstrcat(temporary," /clip_compile_view");
+
+		//コンパイラビューを閉じる
+		extern HWND hCompileView;
+		if(hCompileView==(HWND)-1) return;
+		if(hCompileView){
+			hChild=hCompileView;
+			hCompileView=(HWND)-1;
+			SendMessage(hChild,WM_COMMAND,IDCANCEL,0);
+		}
+
+		//重複起動防止のため
+		hCompileView=(HWND)-1;
+	}
+
+	//インクルードディレクトリ
+	sprintf(temp2," /include_dir:\"%s\"",pobj_nv->GetIncludeDirFullPath().c_str());
+	lstrcat(temporary,temp2);
+
+	extern ActiveBasic::Common::Platform::EnumType selectingPlatform;
+	CreateProcessWithStdHandle( ActiveBasic::Common::Environment::GetCompilerExePath( selectingPlatform ), temporary );
+}
+
+void MainFrame::OnCmdDebugCompile( UINT uNotifyCode, int nID, CWindow wndCtl )
+{
+	char temporary[1024], temp2[1024], temp3[1024];
+
+	HWND hChild=::GetWindow(hClient,GW_CHILD);
+	if(ProjectInfo.name[0]){
+		//プロジェクトが開かれている場合
+		if(!SetProjectToRun()) return;
+
+		//ソースファイル名をtemp2へ
+		ProjectInfo.pobj_DBFileInfo->ppobj_FileInfo[0]->GetFullPath(temp2);
+
+		//出力ファイル名をtemp3へ
+		lstrcpy(temp3,ProjectInfo.lpszOutput_Debug);
+		GetFullPath(temp3,ProjectInfo.dir);
+
+		sprintf(temporary,"\"%s\" \"%s\" /debug /wnd:%08x",temp2,temp3,m_hWnd);
+
+		//DLLオプション
+		if(ProjectInfo.dwModuleType==MT_DLL) lstrcat(temporary," /dll");
+
+		//Unicodeオプション
+		if(ProjectInfo.dwOption & PJ_OP_UNICODE) lstrcat(temporary," /unicode");
+	}
+	else{
+		//単独ソースコード
+		if(!SetRunning(hChild)) return;
+		sprintf(temporary,"\"%s\" /debug /wnd:%08x",MdiInfo[GetWndNum(hChild)].path,m_hWnd);
+	}
+
+	//コンパイルビューをクリップするかどうか
+	extern BOOL bClipCompileView;
+	if(bClipCompileView){
+		lstrcat(temporary," /clip_compile_view");
+
+		//コンパイラビューを閉じる
+		extern HWND hCompileView;
+		if(hCompileView==(HWND)-1) return;
+		if(hCompileView){
+			hChild=hCompileView;
+			hCompileView=(HWND)-1;
+			SendMessage(hChild,WM_COMMAND,IDCANCEL,0);
+		}
+
+		//重複起動防止のため
+		hCompileView=(HWND)-1;	
+	}
+
+	//インクルードディレクトリ
+	sprintf(temp2," /include_dir:\"%s\"",pobj_nv->GetIncludeDirFullPath().c_str());
+	lstrcat(temporary,temp2);
+
+	extern ActiveBasic::Common::Platform::EnumType selectingPlatform;
+	CreateProcessWithStdHandle( ActiveBasic::Common::Environment::GetCompilerExePath( selectingPlatform ), temporary );
+
+}
+
+void MainFrame::OnCmdAttach( UINT uNotifyCode, int nID, CWindow wndCtl )
+{
+	char temporary[1024], temp2[1024];
+
+	int idProcess;
+	DWORD dwPlatform;
+	idProcess=DialogBoxParam(hResInst,MAKEINTRESOURCE(IDD_ATTACH),m_hWnd,(DLGPROC)DlgAttach,(LPARAM)&dwPlatform);
+	if(idProcess==0) return;
+
+	sprintf(temporary,"/attach:%08x /wnd:%08x",idProcess,m_hWnd);
+
+	//コンパイルビューをクリップするかどうか
+	extern BOOL bClipCompileView;
+	if(bClipCompileView){
+		lstrcat(temporary," /clip_compile_view");
+
+		//コンパイラビューを閉じる
+		extern HWND hCompileView;
+		if(hCompileView==(HWND)-1) return;
+		if(hCompileView){
+			HWND hChild=hCompileView;
+			hCompileView=(HWND)-1;
+			SendMessage(hChild,WM_COMMAND,IDCANCEL,0);
+		}
+
+		//重複起動防止のため
+		hCompileView=(HWND)-1;
+	}
+
+	//インクルードディレクトリ
+	sprintf(temp2," /include_dir:\"%s\"",pobj_nv->GetIncludeDirFullPath().c_str());
+	lstrcat(temporary,temp2);
+
+	ActiveBasic::Common::Platform::EnumType platform;
+	if(dwPlatform==IMAGE_FILE_MACHINE_I386)
+	{
+		platform = ActiveBasic::Common::Platform::X86;
+	}
+	else if(dwPlatform==IMAGE_FILE_MACHINE_AMD64)
+	{
+		platform = ActiveBasic::Common::Platform::X64;
+	}
+	else
+	{
+		throw;
+	}
+
+	extern ActiveBasic::Common::Platform::EnumType selectingPlatform;
+	CreateProcessWithStdHandle( ActiveBasic::Common::Environment::GetCompilerExePath( platform ), temporary );
+}
+
+void MainFrame::OnCmdReleaseCompile( UINT uNotifyCode, int nID, CWindow wndCtl )
+{
+	char temporary[1024], temp2[1024], temp3[1024];
+
+	HWND hChild=::GetWindow(hClient,GW_CHILD);
+	if(ProjectInfo.name[0]){
+		//プロジェクトが開かれている場合
+		if(!SetProjectToRun()) return;
+
+		//ソースファイル名をtemp2へ
+		ProjectInfo.pobj_DBFileInfo->ppobj_FileInfo[0]->GetFullPath(temp2);
+
+		//出力ファイル名をtemp3へ
+		lstrcpy(temp3,ProjectInfo.lpszOutput_Release);
+		GetFullPath(temp3,ProjectInfo.dir);
+
+		sprintf(temporary,"\"%s\" \"%s\" /wnd:%08x",temp2,temp3,m_hWnd);
+
+		//DLLオプション
+		if(ProjectInfo.dwModuleType==MT_DLL) lstrcat(temporary," /dll");
+
+		//Unicodeオプション
+		if(ProjectInfo.dwOption & PJ_OP_UNICODE) lstrcat(temporary," /unicode");
+	}
+	else{
+		//単独ソースコード
+		if(!SetRunning(hChild)) return;
+		sprintf(temporary,"\"%s\" /wnd:%08x",MdiInfo[GetWndNum(hChild)].path,m_hWnd);
+	}
+
+	//コンパイルビューをクリップするかどうか
+	extern BOOL bClipCompileView;
+	if(bClipCompileView){
+		lstrcat(temporary," /clip_compile_view");
+
+		//コンパイラビューを閉じる
+		extern HWND hCompileView;
+		if(hCompileView==(HWND)-1) return;
+		if(hCompileView){
+			hChild=hCompileView;
+			hCompileView=(HWND)-1;
+			SendMessage(hChild,WM_COMMAND,IDCANCEL,0);
+		}
+
+		//重複起動防止のため
+		hCompileView=(HWND)-1;
+	}
+
+	//インクルードディレクトリ
+	sprintf(temp2," /include_dir:\"%s\"",pobj_nv->GetIncludeDirFullPath().c_str());
+	lstrcat(temporary,temp2);
+
+	extern ActiveBasic::Common::Platform::EnumType selectingPlatform;
+	CreateProcessWithStdHandle( ActiveBasic::Common::Environment::GetCompilerExePath( selectingPlatform ), temporary );
+}
+
+void MainFrame::OnCmdReleaseRun( UINT uNotifyCode, int nID, CWindow wndCtl )
+{
+	char temporary[1024], temp2[1024], temp3[1024];
+
+	HWND hChild=::GetWindow(hClient,GW_CHILD);
+	if(ProjectInfo.name[0]){
+/*						//プロジェクトが開かれている場合
+		if(!SetProjectToRun()) return;
+
+		//必要であればリリースコンパイル
+		if(IsNeedCompileForProject(0))
+			SendMessage(WM_COMMAND,IDM_RELEASECOMPILE,0);*/
+
+		if(ProjectInfo.dwModuleType==MT_DLL){
+			lstrcpy(temporary,ProjectInfo.szExePath);
+		}
+		else{
+			lstrcpy(temporary,ProjectInfo.lpszOutput_Debug);
+			GetFullPath(temporary,ProjectInfo.dir);
+		}
+	}
+	else{
+/*						//必要であればリリースコンパイル
+		if(!SetRunning(hChild)) return;
+
+		if(IsNeedCompile(MdiInfo[GetWndNum(hChild)].path,0))
+			SendMessage(WM_COMMAND,IDM_RELEASECOMPILE,0);*/
+
+		//単独ソースコード
+		_splitpath(MdiInfo[GetWndNum(hChild)].path,temporary,temp2,temp3,NULL);
+		lstrcat(temporary,temp2);
+		lstrcat(temporary,temp3);
+		lstrcat(temporary,".exe");
+	}
+
+	//インクルードディレクトリ
+	sprintf(temp2," /include_dir:\"%s\"",pobj_nv->GetIncludeDirFullPath().c_str());
+	lstrcat(temporary,temp2);
+
+	ShellExecute(m_hWnd,"open",temporary,NULL,NULL,SW_SHOWNORMAL);
+}
