Hi all,
I have created the access token in the windows c# application. Like the below code,
result = await app.AcquireTokenInteractive(scopes)
.WithAccount(firstAccount)
.WithParentActivityOrWindow(new WindowInteropHelper(this).Handle)
.WithPrompt(Prompt.SelectAccount)
.ExecuteAsync();
In this, the WindowInteropHelper got error because it contains the "System.Windows.window" as parameter. Is there any option to set this WindowInteropHelper in the "System.Windows.Forms.Form" page?
Thanks.

Tamil RkPosted Jul 20, 2021, 1:25 PM
Hello RAJA PRIYA,
For windows form we can use like below:
.WithParentActivityOrWindow(Handle)
Windows wpf :
.WithParentActivityOrWindow(new WindowInteropHelper(this).Handle)
Shweta LodhaPosted Jul 19, 2021, 11:14 PM