Office.InfobarClickedEventArgs interface
Enthält grundlegende Details zur Benachrichtigung, die das Office.EventType.InfobarClicked Ereignis ausgelöst hat.
Hinweise
Beispiele
// Adds an event handler for the InfobarClicked event.
Office.onReady(() => {
document.addEventListener('DOMContentLoaded', () => {
// Get a reference to the mailbox and use it to add an event handler.
const mailbox = Office.context.mailbox;
mailbox.addHandlerAsync(Office.EventType.InfobarClicked, infobarClickedHandler, (result) => {
if (result.status === Office.AsyncResultStatus.Failed) {
console.error(`Failed to add event handler: ${asyncResult.error.message}`);
return;
}
console.log("Event handler added successfully.");
});
});
});
// Handles the InfobarClicked event.
function infobarClickedHandler(event) {
console.log(`Event: ${event.type}`);
const infobarDetails = event.infobarDetails;
console.log(`Notification type: ${infobarDetails.infobarType}`);
console.log(`Action type: ${infobarDetails.actionType}`);
}
Eigenschaften
| infobar |
Ruft zusätzliche Details zur Benachrichtigung ab. |
| type | Ruft den Typ des Ereignisses ab. Weitere Informationen finden Sie unter Office.EventType. |
Details zur Eigenschaft
infobarDetails
Ruft zusätzliche Details zur Benachrichtigung ab.
infobarDetails: InfobarDetails;
Eigenschaftswert
Hinweise
type
Ruft den Typ des Ereignisses ab. Weitere Informationen finden Sie unter Office.EventType.
type: "olkInfobarClicked";
Eigenschaftswert
"olkInfobarClicked"