Category ".net-core"

Consume SSL Secured APIs in ASP.NET Core 6 MVC Client

We have an application that has two projects as follows (1) AppClient – This dotnet core MVC project and it is running on WebServer on IIS (2) AppService

dotnet core Subscriber is not being triggered after Publishing

I'm working on a Redis(StackExchange.Redis) PUBSUB system in Dotnet core and everything works normally until after I publish to my channel. The subscriber simpl

Performance of c# FileStream.Seek vs FileStream.ReadBytes. Why is the latter faster?

In my application I need to frequently move the position pointer of a file stream forward a small number of bytes. Experimentation with using FileStream.ReadByt

Is there any way to get Graph API event reminder through subscription?

We have multiple reminders like 5 minutes , 15 minutes and 30 minutes. We store them in our own database and send maximum time reminder with graph API create ev

MSB4803: The task "ResolveComReference" is not supported on the .NET Core version of MSBuild

I have used Microsoft.Office.Interop.Excel reference in com. And the above error is coming in deployment. Below is the com reference that is in .csproj file of

Error: The type or namespace name 'DesignAutomation' does not exist in the namespace 'Autodesk.Forge'

I'm trying to run Forge Sample to scale a model using .Net Core. I get the Error: The type or namespace name 'DesignAutomation' does not exist in the namespace

RouteBuilder vs EndpointRoutBuilder in .Net

I am trying to learn behind the scene of Routing and I find out that WebApplication implements IEndpointRouteBuilder which allows it to define routes for exampl

Linq Nullable object must have a value. errors in .NET 6 and EF Core

I have this code: IQueryable<WinnerClassExtend> dataList = from Class in _context.AllClass join Winner in _context.AllWinners on Class.ClassId equals Win

Interop Crypto OpenSslCryptographicException: error:14094410:SSL routines:ssl3_read_bytes:sslv3 alert handshake failure

No matter target to net5.0 or net6.0 framework, when trying to create a sslstream, it repeatedly throw the error running on Ubuntu OS while works on Windows OS,

Getting a SameSite cookie issue when trying to load recaptcha api.js in ASP.Net core project

I am trying to add a Google v2 reCaptcha on my ASP.Net Core 6 Web Application and test it on my localhost. When I add the following line: <script src="ht

How to whitelist packages in azure devops?

Strange question - I want to whitelist packages for dotnet build, like use only allowed packages. I'm using Azure DevOps as a build/deploy solution. For example

Unit Testing Works in VSCode on Windows but not Linux

I'm having trouble debugging Xunit unittests in .NET6 running on Ubuntu 20.04 in VSCode (1.66.2). These run in VisualStudio and VSCode in Windows. I can run (no

WPF Control lagging behind children WebView2 control

I am trying to make a draggable window sort of thing in wpf (.net core 6) and I am using webview2 to make a browser window. However I discovered this strange be

Validate Requests in NSwag generated Client

I have a .NET 6 Webclient and REST Contract, that is generated from a YAML with NSwag. The contract contains some validation properties. Is there any way to val

Generically Register All Concrete types for Lazy Loading in DI

I want to setup Lazy Loading of registered types in a generic way that does not require me to register each one individually. I can create an extension method t

Brand new Monodevelop installation can't restore packages

I'm trying to use MonoDevelop in order to work with .NET Core. In a brand new Linux Mint 20.1 machine, I installed MonoDevelop 7.8.4, and opened a project that

Can we pass 3 url to backend(asp.net core, 1 master, 2 slave) appsettins.json have 1 connectionstring yandex cloud? postgresSql master-slave

We have datacenter in 3 zone and 3 different url. Connect to database postgres is psql "hostname=url1,url2,url3 \port=......" Yandex understand what is master n

Using `await` in AuthorizationHandler

I have a AuthorizationHandler depending on a Service offering async methods for .NET Core 3.1's Authorization Middleware. I have o call some of these async meth

How to reduce size of winforms executable in .Net6?

I am very new to .Net6 and .Net Core in general. I understand that it is possible to publish a single file executable but I was a bit surprised to see that the

Easier way in .net Avalonia to change the background color of the Window's System Top bar?

In dotnet's Avalonia-UI framework. I'm using a dark UI and I managed to make everything dark as per this example but one thing: the window's System top bar in W