Notifications


NotificationMessages

There are three types of notification messages
1 - Progress indicator
2 - Informational messages
3 - Error message


You should always show a success or error message so users know if the operation fully succeeded, or just partially.
The processing for notifications must be defined in a separate HTML file specified by the FunctionFile node of the manifest.


Office.context.document.item.notificationMessages.addAsync( 
   "Key",
   { type:"informationalmessage",
     icon: "iconid",
     message: "mymessage",
     persistent:true},
     function (asyncResult){
           if (asyncResult.status == "failed") {
                 showMessage("error message:" + asyncResult.error.message);
     }
} );



User Interaction/Notification

see page app.initialize ??

app.showNotification = function(header, text) { 
   $('#notification-message-header').text(header);
   $('#notification-message-body').text(text);
   $('#notification-message').slideDown('fast');
}


??

??P  

© 2016 Better Solutions Limited | All Rights Reserved

    Next