Questions

Entity Framework data migration with custom logic?

Suppose, I want to replace table `A` with table `B` and migrate all data from one to another, so I do: 1. Create table B through SQL query 2. Perform transformation over entire copy of data from A f...

7 Feb at 19:35

C# async/await for I/O-Bound vs CPU-Bound operation

I am learning about asynchronous programming in C#. In [this][1] article I found that for IO-Bound operations you should not use `Task.Run()` but I don't know how to create a task without Task.Run().....

22 May at 04:21

ASP.Net Core 2 error handling: How to return formatted exception details in Http Response?

I am looking for a way to return the details of any exception that occur when calling a method of my web API. By default in production environment, error 500 "Internal Server Error" is the only infor...

How to load navigation properties on an IdentityUser with UserManager

I've extended `IdentityUser` to include a navigation property for the user's address, however when getting the user with `UserManager.FindByEmailAsync`, the navigation property isn't populated. Does A...

ServiceStack Licensing Model

I've purchased a license in the past. Now that it's expired, do I have to purchase a new license to continue using ServiceStack? Will there be any rate limits or anything else if I don't purchase?

5 Feb at 11:31

ServiceStack System.IndexOutOfRangeException at JsvTypeSerializer.EatMapKey

In my logs, I found a weird error regarding my ServiceStack service. I don't have further information than the following stacktrace and I didn't manage to reproduce the error yet. That's the stacktrac...

Error: The method or operation is not implemented. while scaffolding MYSQL Database

I'm using .net core 2.0. I have installed the following nuget Packages: 1: `Microsoft.AspNetCore.All` 2: `Microsoft.EntityFrameworkCore.Tools` 3: `MySql.Data.EntityFrameworkCore` 4: `MySql.Data.Entity...

5 Feb at 06:14

bootstrap 4 file input doesn't show the file name

I have a problem with the custom-file-input class in Bootstrap 4. after I chose which file I want to upload the filename do not show. I use this code: ``` <div class="input-group mb-3"> <div class...

Why doesn't this deadlock in ASP.NET Core Web API?

I read 's post [Don't Block on Async Code](https://blog.stephencleary.com/2012/07/dont-block-on-async-code.html), so I created an project: ``` class AsyncTest { public async Task<string> DoSomet...

Unable to start program. [VALUE].dll is not a valid Win32 application error in Visual Studio 2017

I have developed an C#, ASP.NET web application in a Windows 7 machine using Visual Studio 2012. Now i had imported the entire project into VS 2017 running on windows 10 machine, and when i try to ent...

3 Feb at 23:11

Maven equivalent in .NET C#

Let's assume there are two Maven Java projects, A and B. A has a dependency on B. B is placed in remote Maven repository and also on GitHub. In IntelliJ Idea IDE, I will open project A and also B (B i...

Is there any way to set environment variables in Visual Studio Code?

Could you please help me, how to setup environment variables in visual studio code?

Cannot use 'dotnet ef...' - The specified framework version '2.0' could not be parsed

My project builds without any issues and can run without issues, but I cannot use `dotnet ef migrations` because of this strange error: ``` The specified framework version '2.0' could not be parsed T...

firebase.auth is not a function

I am using Webpack with firebase and firebase-admin. To install firebase I ran: ``` npm install --save firebase ``` I am importing firebase using: ``` import * as firebase from 'firebase/app' import ...

9 Jan at 08:32

How to add my own properties to Serilog output template

I have a small application that is receiving messages from a service bus, which can send through several different types of events for different users. Based on the type of event, a different function...

2 Feb at 22:31

How to execute a lot of durable functions triggered by Azure Queue?

If briefly, our task is to process a lot of input messages. To solve this we decided to use Azure Queue Storage and Azure Functions. We have Azure Functions structure similar to the following code: ...

12 Dec at 14:18

Prelaunch task build terminated with exit code 1

I'm trying to learn how to create method libraries but whenever I run my program a little pop-up window (with a surprisingly basic Windows graphical interface, post-update) shows up with the message "...

Cannot resolve scoped service from root provider .Net Core 2

When I try to run my app I get the error ``` InvalidOperationException: Cannot resolve 'API.Domain.Data.Repositories.IEmailRepository' from root provider because it requires scoped service 'API.Doma...

3 Feb at 00:41

Deprecate specific route out of multiple routes on single Web API method

Hi I have WEB API implementation as shown below. Where we are using multiple routes on single method. ``` [SwaggerOperation("Update Records By Id")] [Route("/construction/field-record")] [Route("/cons...

VSCode showing only one file in the tab bar (can't open multiple files)

I hit some shortcut and I can't find the setting the turn it off. But opening multiple files doesn't show different tabs. Here's what I'm seeing [](https://i.stack.imgur.com/7aLOc.png) But this is ...

2 Feb at 19:40

Which TLS version was negotiated?

I have my app running in .NET 4.7. By default, it will try to use TLS1.2. Is it possible to know which TLS version was negotiated when performing, for example, an HTTP Request as below? ``` HttpWebRe...

9 Feb at 16:44

Is there TypedClient support in StackExchange.Redis C# client?

I'm comparing capabilities of ServiceStack.Redis and StackExchange.Redis clients. I thought that it might be very useful to use `IRedisTypedClient<T>` class of ServiceStack.Redis client. Just wonde...

.NET Core WebAPI dependency injection resolve null

I use .NET Core WebAPI with dependency injection and multiple authentication schemas (http basic, access keys, JWT). I inject some business services which require some authenticated user data. If user...

Overloading in local methods and lambda

``` static void Main() { void TestLocal() => TestLocal("arg"); TestLocal("arg"); } static void TestLocal(string argument) { } ``` In this example, local function has the same name as another met...

6 Feb at 08:51

How Decompress Gzipped Http Get Response in c#

Want to Decompress a Response which is GZipped Getting from an API.Tried the Below Code ,It Always return Like:- ``` \u001f�\b\0\0\0\0\0\0\0�Y]o........ ``` My code is: ``` private string GetRespo...

2 Feb at 09:28