You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
However, if null is passed in to the ownerWindow, the following error is thrown: Unhandled Exception: System.PlatformNotSupportedException: Possible Cause: If you are using an XForms app, or generally a netstandard assembly, make sure you add a reference to Microsoft.Identity.Client.dll from each platform assembly (e.g. UWP, Android, iOS), not just from the common netstandard assembly
The error should be something like: On the Android platform the ownerWindow cannot be null. An Activity must be passed to the ownerWindow in the AcquireTokenInteractive Call. Please see https://aka.ms -something cool for more details and a code sample
confirmed that when passing in a null ownerWindow on Android, we throw a correct exception w/a clear error message: InvalidOperationException: Activity is required for parent object on Android.
Closing, as I think @bgavrilMS is right and the second part of this issue is a duplicate.
Documentation Related To Component:
In Msal v3, developers must pass in an Activity for the ownerWindow on Android.
For example:
However, if null is passed in to the ownerWindow, the following error is thrown:
Unhandled Exception: System.PlatformNotSupportedException: Possible Cause: If you are using an XForms app, or generally a netstandard assembly, make sure you add a reference to Microsoft.Identity.Client.dll from each platform assembly (e.g. UWP, Android, iOS), not just from the common netstandard assembly
The error should be something like:
On the Android platform the ownerWindow cannot be null. An Activity must be passed to the ownerWindow in the AcquireTokenInteractive Call. Please see https://aka.ms -something cool for more details and a code sample
Please check those that apply
See related issue
The text was updated successfully, but these errors were encountered: