HI Team,
I am having a normal Asp.Net Framework application. In this application i have Aspx.cs file which gets the data that user is inputing on Aspx.Page. Now i am trying to authentciate this application with Dynamics 365 using Azure Active Directory. As everyone Aware of that it can be done by creating Application User in Dynamics 365 and also Registering Application in Azure Active Directory through Azure Portal.
By using Console Application i can get the token and authetication process has been done successfully but when i place the same code in Aspx.cs file I am facing a issue with Authentication and the application was hanging when the debugging point come AuthenticationParameter.

The code which was in the picture was in ASPX.cs file
Please kindly Help me on this!!!
Kind Regards
Santiii