I have created my first non Delphi Ribbon using the Microsoft Ribbon Framework thanks to the help and advice provided in this thread.
Following the guide that A.Bouchez posted in that thread I have managed to compile my project and see the Microsoft Ribbon in action.
However, I cannot seem to get the Ribbon to respond to input when a Command is executed.
I always use the TActionManager to manage my Events, so all I need is to link each TAction from the TActionManager into the Ribbon. Following the tutorial linked above, I tried the following to no avail:
// actNew is the name of a TAction set in the TActionManager
procedure TfrmMain.actNewExecute(Sender: TObject);
begin
ShowMessage('execute new event');
end;
procedure TfrmMain.CommandCreated(const Sender: TUIRibbon; const Command: TUICommand);
begin
inherited;
case Command.CommandId of
cmdNew: // cmdNew was defined in the Ribbon Designer
begin
// link the ribbon commands to the TActions
actNew.OnExecute(Command as TUICommandAction); // obviously will not work
end;
end;
end;
So, how do I assign my TActions to the Ribbon?
Thanks.