This documentation is archived and is not being maintained.


Specifies the priority of attributes or keywords in the context bag.

Namespace:  Microsoft.VisualStudio.Shell.Interop
Assembly:  Microsoft.VisualStudio.Shell.Interop (in Microsoft.VisualStudio.Shell.Interop.dll)


Member nameDescription
VSUC_Priority_NoneDefault; lowest priority level. This value is only used internally by the environment.
VSUC_Priority_AmbientLow priority level. Typically reserved for start pages, getting started topics, and so on. This value is applied to information which provides useful, but not very specific, Help information.
VSUC_Priority_StatePriority level for command UI context.
VSUC_Priority_ProjectPriority level for a hierarchy.
VSUC_Priority_ProjectItemPriority level for a hierarchy item.
VSUC_Priority_WindowPriority level for an editor window. Used by Solution Explorer because it also pushes a selection to the Properties window.
VSUC_Priority_SelectionPriority level for a selection container.
VSUC_Priority_MarkerSelPriority level for a selection container.
VSUC_Priority_EnterprisePriority level for enterprise templates.
VSUC_Priority_WindowFramePriority level for tool windows that do not want to overwrite SEID_UserContext, but want their context to appear at the top of the RL window.
VSUC_Priority_ToolWndSelPriority level for a selection within a tool window. For example, this value could be assigned to a command within the command window.
VSUC_Priority_HighestSpecifies the highest priority of any keyword. Priority level for wizards accessed through the automation model.

Each IVsUserContext object is associated with one of the priority values specified by the VSUSERCONTEXTPRIORITY enumeration. In general, these values are set automatically by the environment when a context bag is created. For example, a priority of VSUC_Priority_WindowFrame is automatically assigned to a tool window.

Command windows contain both a context for the command window itself, and a subcontext for a selection within the command window. The priority level for subcontext is set when you link the subcontext bag to the parent context bag by calling AddSubcontext. In this method, specify the subcontext bag in the pSubCtx parameter and then the priority in the lpriority parameter. In the case of a command window selection, the new subcontext is assigned a priority value of VSUC_Priority_ToolWndSel.

COM Signature

From vsshell.idl: