Пример #1
0
void CMainWindow::OnToolsQueryWizard() {
	string qwPath = preferences.GetHomePath() + "QueryBuilder.exe";
	if ( GetFileAttributes( qwPath.c_str() ) == -1 ) {
		MessageBox( "QueryBuilder is not installed.", "StudentInfo" );
	} else {
		if ( (int)ShellExecute( NULL, "open", qwPath.c_str(), NULL, preferences.GetHomePath().c_str(), SW_SHOWNORMAL ) <= 32 ) {
			MessageBox( "Unable to execute QueryBuilder.", "StudentInfo" );
		}
	}
}
Пример #2
0
void CMainWindow::OnUpdateToolsQueryWizard( CCmdUI* pCmdUI ) {
	pCmdUI->Enable( GetFileAttributes( ( preferences.GetHomePath() + "QueryWizard.exe" ).c_str() ) != -1 );
}