Skip to content

Instantly share code, notes, and snippets.

View johnmorse's full-sized avatar

John Morse johnmorse

View GitHub Profile
@johnmorse
johnmorse / gist:5861350
Created June 25, 2013 19:01
Demonstrates how to open a RUI file and display a specific tool bar group.
static bool ShowGroupFromRuiFile(const wchar_t* fullPathToRuiFile, const wchar_t* groupName, bool showFirstFroupIfNotFound)
{
ON_wString ruiFileName(fullPathToRuiFile);
if (ruiFileName.IsEmpty())
return false; // No RUI file name specified
// This flag should always be false since we are dealing with full path names
// and not RUI file aliases
bool nameIsAlias = false;
// Check to see if the file is open, there is nothing wrong with just calling
// FileOpen since it simply returns the currently open file UUID if the file