Add a shape click handler to a PowerPoint Add-in

35 Views Asked by At

I'm creating a PowerPoint web addin and I need to add a click handler to run some code when a user "clicks" on any shape in a presentation. For now, I can find only the next approach:

Office.context.document.addHandlerAsync(
  Office.EventType.DocumentSelectionChanged, () => console.log('my code here'),
);

It works, but when I need to handle two clicks in a row - it doesn't. The reason is no selections changed.

I'd like to find a "native" approach to handle the "click" event of shapes.

0

There are 0 best solutions below