Category "asp.net"

How do I solve error with Active Directory Search using user name

Im using the the below C# code to try search active directory for a user's email address by passing username. but this returns error using System.Text; using S

Override and New Keywords (C# Programming)

Understand that Override and New Keywords can help to either implement the base methods or the child methods. But when using the real time examples, I don't see

ASP.Net WebSocket how to simulate error event?

I just want to do like this on ASP.NET WebSocket. When my WebSocket server catches internal server error, I want my WebSocket server to send an error to clients

Asp.Net Client Certificate Authentication - Issue with website re-prompting for client PIN

I have an ASP.NET 5 web application that is setup to use client certificate authentication, specifically a DoD CAC. I followed Microsoft's guidance (here) to se

How to restrict a download in asp.net web forms?

I have this code in the page_load method of an ASP.NET .aspx page that downloads a particular file from the same web site: System.IO.FileInfo file = new System.

System.UnauthorizedAccessException in mscorlib.dll

I was developing an ASP.NET application. Then I did not test the application in the debugger of Visual Studio, but transferred it via File Deploy to another ser

Problem running DAPR with docker-compose in ASP .NET core 3.1

I'm trying to run multiple microservices with docker-compose relying on DAPR to establish communication between them. However, even though developer shell logs

OnItemDataBound in Datalist on how to show and hide labels and linkbuttons

I have a datalist with some labels and link button. I want to hide and show based on some stored procedure. The stored procedures are woprking fine in SQL Serve

Customize col on a kendoGrid data

Hi all I have done download a kendoGrid data to excel part as below. $("#1").data("kendoGrid").saveAsExcel(); kendogrid column are below 1.ist 2.7st 3.8sy colu

How to generate heap overflow error using c#

I want generate a heap overflow error and slow down the system, however I have created alot of objects on class level, later on creating that class object milli

How to add bearer token authentication to typed HttpClient in Asp.Net Core 6

I'm trying to setup a web api using ASP.Net Core 6 so that users can hit my end points and then I do some work in D365 behind the scenes using a privileged acco

How to use "Azure storage blobs" for POST method in controller

I am creating an app where user can upload their text file and find out about its most used word. I have tried to follow this doc to get used to the idea of us

Microservice architecture Database rollback

I am having a microserice architecture with multiple services, each containing their own Database, and a Gateway which is considered as the business logic. Gat

The entity type 'Access' requires a primary key to be defined. If you intended to use a keyless entity type call 'HasNoKey()'

i have this ValueObject : public class Access : ValueObject<Access> { public string ControllName { get; set; } public string ActionName { get;

message shows undefined when ajax post in ASP.net

Hi I'm Fairly new at coding and in asp.net and had an error occurred to me please help me if you can. This is my script when I run the code given below using an

How to properly implement authorization code flow in .NET?

I am trying to properly implement Authorization Code flow for a 3rd party REST api for my users to use. However, I am not sure if I am doing it correctly with t

Issue after deploying ASP.NET Web API to production

I tested ASP.NET Web API in local environment with IIS Express and on other server with full IIS. At both places, token api and post api is working fine. I am u

How to fix 500.30 - ASP.NET CORE app failed to start

Well after publishing the program on IIS, we have this error HTTP Error 500.30 - ASP.NET Core app failed to start Common solutions to this issue: The app failed

Could not load file or assembly 'Microsoft.IdentityModel.Protocols.WsFederation

I have a ASP.NET legacy project to which ADFS authentication needs to be added. So I did the same but when I run the application, I keep getting this error:

Cannot load System.Web.HttpContext error with razor pages and WebMail

I've been having trouble getting WebMail to work sending an email using a contact form using This Official Microsoft Tutorial. My current issue is that I'm get