disable case sensitive in visual studio solution explorer

In the visual studio solution explorer, when a word is written in lower case then the solution explorer filters the word as not case-sensitive but if one letter is written in upper case then it wil...

Where are Entity Framework Core conventions?

using EF 6.1+ there were times where we need to add or remove existing conentions. The code looks more or less like: ``` public class MyContext : DbContext { protected override void O...

19 Oct at 19:37

ServiceStack resolving\throwing 404 depending on the order of the methods in my IService?

``` public class UgGroupEditorService : IService { public object Get(GroupsRequest request){} public object Post(GroupsRequest request){} public object Get(GroupsHelloRequest request) { ...

19 Oct at 18:29

How Mock JsonReader unit testing a custom JsonConverter

Wrote a Custom JsonConverter to handle different Json formats that are returned by different versions of the same api. One app makes a request to several other apps, and we dont know which format will...

19 Oct at 17:11

ThreadPool SetMinThreads - the impact of setting it

I am trying to understand the impact of setting `ThreadPool.SetMinthreads`. I have multiple virtual applications running in one Azure App Service. My understanding is that all these virtual applicatio...

Automatic Binding Redirects

Running VS 2017, latest update. The [documentation](https://learn.microsoft.com/en-us/dotnet/framework/configure-apps/how-to-enable-and-disable-automatic-binding-redirection) states that to enable au...

19 Oct at 15:14

Get safe area inset top and bottom heights

What would be the most proper way to get both top and bottom height for the unsafe areas? [](https://i.stack.imgur.com/hQXf7.png)

how to open Jupyter notebook in chrome on windows

On my Windows PC, i have anaconda installed and when I open a jupyter notebook, it opens up in internet explorer, but I would like to use Chrome instead. Does anyone know how to achieve this?

PyTorch: How to get the shape of a Tensor as a list of int

In numpy, `V.shape` gives a tuple of ints of dimensions of V. In tensorflow `V.get_shape().as_list()` gives a list of integers of the dimensions of V. In pytorch, `V.size()` gives a size object, but...

19 Oct at 08:59

How can I use a generic type with entity framework core?

If I have a domain model that looks something like this: ``` public class Foo<T> { public Guid Id { get; set; } public string Statement { get; set; } public T Value { get; set; } } ``` ...

19 Oct at 08:57

Event vs EventHandler

I read a lot of materials but I still did not understand, can someone explain me, please? What do I know: Declare an event: ``` public event MyEvent myEvent; ``` Vs. declare EventHandler: ```...

19 Oct at 07:21

SignInAsync vs AuthenticateAsync

I finally got my login-method with JWT Token Authentication working. Here I'm calling ``` await HttpContext.SignInAsync( CookieAuthenticationDefaults.AuthenticationScheme, ClaimsPrincipalFa...

Why does Visual Studio mark my added .cs files as "ignored"?

I cloned an existing but almost empty project on my local machine through GitHub for Windows. Then I opened it in VS 2017 and added a few classes after what they all became marked up as "ignored" with...

31 Dec at 15:11

Provide Intellisense for Custom MarkupExtension in XAML

I've created a custom `MarkupExtension` that allows an easy way to to forward events from `FrameworkElements` to methods on the view-model. Everything works perfectly, except Visual Studio doesn't pr...

How to add external assembly (.dll) to .NET Core 2.0 on Visual Studio Code

I faced some issues regarding adding an external assembly (`.dll`) to my `.NET Core 2.0` console application on as there are little to none documentation about how you can do it. Microsoft provides ...

What is the best way to convert Newtonsoft JSON's JToken to JArray?

Given an array in the JSON, I am trying to find the best way to convert it to JArray. For example - consider this below C# code: ``` var json = @"{ ""cities"": [""London"", ""Paris"", ""New York""]...

18 Oct at 16:8

Handling Exceptions in a Base Controller with ASP.net core (API controller)

Many of our current controllers look like this: A lot of code is being repeated here though. What I'd like to do is implement a base controller that handles exceptions so I can return a *standardized ...

Select columns in PySpark dataframe

I am looking for a way to select columns of my dataframe in PySpark. For the first row, I know I can use `df.first()`, but not sure about columns given that they do I have 5 columns and want to loop ...

ASP.NET Core 2 - Multiple Azure Redis Cache services DI

In ASP.NET Core 2 we can add a Azure Redis Cache like this: ``` services.AddDistributedRedisCache(config => { config.Configuration = Configuration.GetConnectionString("RedisCacheConnection"); ...

.Net Core 2.0 Process.Start throws "The specified executable is not a valid application for this OS platform"

I need to let a .reg file and a .msi file execute automatically using whatever executables these two file types associated with on user's Windows. [.NET Core 2.0 Process.Start(string fileName) docs](...

18 Oct at 10:42

Searching Active Directory B2C by custom property on User

We are using B2C and storing customer numbers as a Extension field on users. A single user can have one or more customers and they are stored in a comma separated string. What I am doing now is high...

5 Dec at 11:8

Mock Static class using moq

I am writing unit test cases with the help of NUnit and have some static classes that I need to mock to run test cases so can we mock static class with the help of mocking framework? Please suggest ...

6 Feb at 00:28

Is it possible to pass a Service Filter parameters?

I know that with regular Filters you can pass parameters like so: I have a Service Filter: The filter has some services injected into it. But each time I use the service I will also be sending in a pa...

6 May at 00:57

How to bind a DataGridView to a SQLite Database?

I'm trying to add a data connection to a datagridview that uses SQLite. I've added the reference to SQLite (downloaded the required files) but when I go through the wizard to add a data source, SQLite...

27 Nov at 10:39

.net Core 2.0 - Package was restored using .NetFramework 4.6.1 instead of target framework .netCore 2.0. The package may not be fully compatible

I have a .net core 2.0 console app. I'm trying to read files from TFS using the following: [How to get a file from TFS directly into memory (i.e., don't want to read from file system into memory)?]...

17 Oct at 19:36