Category "c++sharp"

Logging errors by serilog-timings at loglevel "Error"

I show my idea on the serilog-timing example. public static void Main(string[] args) { Log.Logger = new LoggerConfiguration() .Enrich.FromLogContext

Entity Framework Core 5 and CosmosDB SQL API - Include extension method does not work

I have followed the steps from the following EF Core 5 site in order to store and read items from the CosmosDB. Here is the site: https://www.learnentityframewo

Move multiple mails to a folder in a different store

I'm using Outlook Redemption library (http://www.dimastr.com/redemption/home.htm) for my Outlook AddIn. I want to move multiple mails from an exchange account t

ASP.NET Exception Error From SQL Server Windows Authentication Login

I have read and tried all the suggestions from [https://stackoverflow.com/questions/22415319/system-data-sqlclient-sqlexception-login-failed-for-user][3] But no

Unity "Multiple precompiled assemblies with the same name" using external dll

I have a "Shared" project where I share code between my client (unity) and my server (C# server) Both projects require Newtonsoft.Json.dll When I compile the Sh

Detecting navigation events blazor webassembly [closed]

How can I detect when URL is changed? I need the event (URL change event) to perform some specific action based on the URL.

In Blazor, how can I dynamically change an HTML tag?

Let's say I have the following markup in my Blazor component: <div @attributes=Attributes data-myattr="something"> @ChildContent </div> I'd lik

EFCore join values

I'm trying to join a big table to a small list of data pairs using EFCore 2.1.1. I want this join to happen server-side, rather than trying to download the who

How to change whole solution's project's name in Visual Studio?

I have ASP.NET CORE C# project. I want to change my solution name and whole project's name. For Example : OldSolution.OldName // this is Solution OldSoluti

Update build reference for test result in Azure DevOps REST API

I have an existing test result and I'd like to update the "Tested build" field for the test result if possible. I've looked at the REST API doc (https://docs.mi

How to avoid login with an empty password field in ASP.NET MVC 5?

I'm working on an ASP.NET MVC 5 project where I have created a customized login and registration page. The application is working fine, but the problem is I am

How to stop host or client in unity netcode?

When I disconnect my server and go to the menu scene, there comes two NetworkManager Objects but a they are implementing the Singleton pattern and it in itself

How could I get a parameter of an action from the ResultExecutingContext when using a Filter

I'm creating a custom result filter that implements IAsyncResultFilter interface. In this filter I need the actual value returned by the Action, but I also need

How can I add persistent data to a mail item so that it is not visible to the user

I have an Outlook add-in that collects data and processes it when the email is sent. Since the email may be saved and sent at a later date the data needs to be

Authorazation with JWT Token - How to get Authorized Automatically

I'm having a problem getting a user to be authorized. I'm making a web Api and in the controller where the login method is, it creates a token (JWT Token / Bear

JetBrains Rider - configure appsettings overrides

I am trying JetBrains Rider for my existing .NET Core project. In the project I have several appsettings.json overrides: appsettings.Development.json - for dev

Check whether string in palindrome : C# code efficiency

I am coming from C background and recently started writing in C# so please don't mind if my question seems somewhat basic. Basically, i want to write a function

How to return HttpStatusCode 404 for incorrect url with FallbackPolicy set in AuthorizationOptions?

In the web application I'm currently working on there is a requirement for all users to be authenticated. This is currently handled by using an AuthorizeFilter.

Is synchronization required when passing a cancel flag with P/Invoke?

I am passing a cancel flag by reference (or by pointer) to a C++ DLL by P/Invoke. The flag will be set at some time in C# code, and the C++ code checks for the

Use Httpclient.GetStreamAsync() is too slow when ipv6 is not disable in C#

Just like C# code, httpClient.GetAsync() use 10 second or more when ipv6 is not disable. But when I disable ipv6 in win10 System, httpClient.GetAsync() just use