Closed kosnkow closed 5 years ago
I created office addin , added necessary scripts but it does not work at all.
I run in in document ready
$(document).ready(() => { if (OfficeHelpers.Authenticator.isAuthDialog()) { return; } var authenticator = new OfficeHelpers.Authenticator(); authenticator.endpoints.registerAzureADAuth("xxxxxxxxxxxxxxx", "xxxxxxxxxxxxx"); authenticator .authenticate(OfficeHelpers.DefaultEndpoints.AzureAD) .then(function (token) { console.log(token) }) .catch(OfficeHelpers.Utilities.log); });
but I can't see any window for logging , the console log only print this http://i.imgur.com/6x6NFfG.png
If i change authenticate to this .authenticate(OfficeHelpers.DefaultEndpoints.AzureAD, true) then I got message: Cannot read property 'displayDialogAsync' of undefined
I created office addin , added necessary scripts but it does not work at all.
I run in in document ready
but I can't see any window for logging , the console log only print this http://i.imgur.com/6x6NFfG.png
If i change authenticate to this .authenticate(OfficeHelpers.DefaultEndpoints.AzureAD, true) then I got message: Cannot read property 'displayDialogAsync' of undefined