JAM-Software / RibbonFramework

Delphi wrapper and standalone Designer for the Windows Ribbon Framework
Other
204 stars 59 forks source link

How I can get RecentItems.LabelText use event TUICommandRecentItems.OnSelect? #119

Closed AzoTik closed 3 years ago

AzoTik commented 3 years ago

Sorry me question. Stackoverflow does not support RibbonFramework. I need get RecentItems.LabelText when use event TUICommandRecentItems.OnSelect.

procedure TForm1.CommandCreated(const Sender: TUIRibbon;
  const Command: TUICommand);
begin
case Command.CommandId of
     //ID команды Paste
    CmdRecItems:
     begin
     FCmdRecItems:=Command as TUICommandRecentItems;
     FCmdRecItems.OnSelect:=RecSelect;
     end;
   end;
end;
procedure TForm1.BitBtn3Click(Sender: TObject);
begin
FCmdRecItems.Add('Проект 1','Рабочий стол');

end;
procedure TForm1.RecSelect(const Command: TUICommandRecentItems;const Verb:TUICommandVerb;
const ItemIndex:Integer;const Propertys:TUICommandExecutionProperties);
var
Item:IUICollectionItem;
begin
Item:=TUIRecentItem.Create('25+25','13+13');
Item:=FCmdRecItems.Items.Items[ItemIndex];
BitBtn3.Caption:=Item.labeltext;
end;

Im not IT specialist, i am Procees Engineer. I need some sample code to repeat.

joachimmarder commented 3 years ago

Please do not misuse our issue tracker for getting support.

joachimmarder commented 3 years ago

Unanswered question => Close