IUIApplication Interface

The IUIApplication interface is implemented by the application and defines the callback entry-point methods for the Windows Ribbon (Ribbon) framework.

IUIApplication Members

OnCreateUICommand Called for each Command specified in the Windows Ribbon (Ribbon) framework markup to bind the Command to an IUICommandHandler.
OnDestroyUICommand Called for each Command specified in the Windows Ribbon (Ribbon) framework markup when the application window is destroyed.
OnViewChanged

Called when the state of a View changes.

Interface Information

Inherits fromIUnknown
Header and IDL filesuiribbon.h, uiribbon.idl
Import libraryuiribbon.dll
Minimum operating systems Windows 7, Windows Vista with Service Pack 2 (SP2) and Platform Update for Windows Vista, Windows Server 2008 R2, Windows Server 2008 with SP2 and Platform Update for Windows Server 2008

See Also

Windows Ribbon Framework Samples
Tags :


Community Content

Arik Poznanski
C# Syntax
// Application callback interface
[ComImport]
[InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
[Guid("D428903C-729A-491d-910D-682A08FF2522")]
public interface IUIApplication
{
// A view has changed
[PreserveSig]
HRESULT OnViewChanged(UInt32 viewId,
UI_ViewType typeID,
[MarshalAs(UnmanagedType.Interface)] object view,
UI_ViewVerb verb,
int uReasonCode);

// Command creation callback
[PreserveSig]
HRESULT OnCreateUICommand(UInt32 commandId,
UI_CommandType typeID,
[Out, MarshalAs(UnmanagedType.Interface)] out IUICommandHandler commandHandler);


// Command destroy callback
[PreserveSig]
HRESULT OnDestroyUICommand(UInt32 commandId,
UI_CommandType typeID,
[MarshalAs(UnmanagedType.Interface)] IUICommandHandler commandHandler);
}
Tags : c# syntax

Page view tracker