Share via


CMFCCmdUsageCount::IsFreqeuntlyUsedCmd

Determines whether the given command is frequently used.

BOOL IsFreqeuntlyUsedCmd(
   UINT uiCmd
) const;

Parameters

Parameter

Description

[in] uiCmd

Specifies the command to check.

Return Value

Nonzero if the command is frequently used; otherwise 0.

Remarks

This method returns 0 if the total command usage, m_nTotalUsage, is 0. Otherwise, this method returns nonzero if the percentage of which the specified command is used is larger than the minimum percentage, m_nMinUsagePercentage. By default, the framework sets the minimum percentage to 5. You can override this value by using the CMFCCmdUsageCount::SetOptions method. If the minimum percentage is 0, this method returns nonzero if the specified command count is larger than 0.

CMFCToolBar::IsCommandRarelyUsed uses this method to determine whether a command is rarely used.

Requirements

Header: afxcmdusagecount.h

See Also

Concepts

MFC Hierarchy Chart

Reference

CMFCCmdUsageCount Class

CMFCCmdUsageCount::SetOptions

CMFCToolBar::IsCommandRarelyUsed