How to exclude folders when using TFS in vscode?

I am using Visual Studio Team Services extension in VS code for check in. [https://marketplace.visualstudio.com/items?itemName=ms-vsts.team](https://marketplace.visualstudio.com/items?itemName=ms-vsts...

4 Jun at 19:37

How to use c# tuple value types in a switch statement

I'm using the new tuple value types in .net 4.7. In this example I am trying to make a switch statement for one or more cases of a tuple: ``` using System; namespace ValueTupleTest { class Progra...

23 Aug at 18:18

AutoMapper define mapping level

``` public class Foo { public string Baz { get; set; } public List<Bar> Bars { get; set; } } ``` When I map the class above, is there any way to define how deep I want automapper to map obje...

4 Jun at 10:28

ServiceStack OrmLite: MySQL connection pool

I understand the topic is not new, I read a few posts but did not come to the answer ... Each time the connection is opened for a very long time, but the idea was to use a connection pool, is not it?...

Task Scheduler failed to start. Additional Data: Error Value: 2147943726

I am using windows 10 task scheduler to run tasks that require me using my personal user account (its necessary to use my user and not system user because of permission issues - I am part of an organi...

How to Per-Request caching in ASP.net core

My old code looks like this: ``` public static class DbHelper { // One conection per request public static Database CurrentDb() { if (HttpContext.Current.Items["CurrentDb"] == null) { ...

Service Stack Razor View Not Found

I added the `RazorPlugin` along with a `Test.cshtml` in the root View folder (tried wwwroot as well along with `TestGet.cshtml`). This is an donet Core project. Whenever browsing to: `/api/test` th...

3 Jun at 20:28

Why does adding an extra field to struct greatly improves its performance?

I noticed that a struct wrapping a single float is significantly slower than using a float directly, with approximately half of the performance. ``` using System; using System.Diagnostics; struct Ve...

4 Jun at 16:11

More than one file was found with OS independent path 'META-INF/LICENSE'

When I build my app, I get the following error: > Error: Execution failed for task ':app:transformResourcesWithMergeJavaResForDebug'. More than one file was found with OS independent path 'META-INF...

14 Feb at 13:29

Next.js - Error: only absolute urls are supported

I'm using express as my custom server for next.js. Everything is fine, when I click the products to the list of products : I click the product Link [](https://i.stack.imgur.com/3UTd4.png) : It will...

3 Jun at 09:9

Check if specific object is empty in typescript

How to check if an object is empty? ex: ``` private brand: Brand = new Brand(); ``` I tried: ``` if (this.brand) { console.log('is empty'); } ``` not working.

12 May at 13:27

Text vertical align in react native (using nativebase)

I was wondering there is a way I can align vertically in React Native. I'm trying to position on the bottom but I don't think I can find a good way to do it. If anyone knows how to solve this issue,...

Moq IServiceProvider / IServiceScope

I am trying to create a Mock (using Moq) for an `IServiceProvider` so that I can test my repository class: ``` public class ApiResourceRepository : IApiResourceRepository { private readonly IServ...

Find and replace in Visual Studio code in a selection

I have the following line in a file I'm editing in VSCode: `...............111.........111.............111..` I want to replace all `.`s with `0`s. However, when I highlight the line and do a find/r...

2 Mar at 20:44

ServiceStack Controllerless Razor Views - Return view without executing service

Right now we have a lot of dummy MVC controllers that return simple views with web components (vuejs). I'm trying to refactor this to see if we can use the controllerless razor plugin but I don't wan...

3 Jun at 16:54

Executing JavaScript on C# with CefSharp WPF causes Error

Whenever I try to execute JavaScript through C# using CefSharp (Stable 57.0), I get an error. I am simply trying to execute the alert function, so I can make sure that works and later test it out with...

5 Jun at 15:33

Entity Framework Core: Update relation with Id only without extra call

I'm trying to figure out how to deal with 'Single navigation property case' described in [this doc:](https://learn.microsoft.com/en-us/ef/core/modeling/relationships) Let's say we have 2 models. ``...

Using the same session for PhantomJs at each run

I'm crawling a secure website which blocks me whenever I restart my crawler application(I need to change IP as a trick). I solved this issue by using default user profile in chrome driver like this (I...

Explanation of a statement by its result

I know, 42 is the answer to everything but how the heck is `42` the result of this? ``` int x = -(~'+'|0xAB^1337); //42 ```

2 Jun at 14:23

How to merge multiple dataframes

I have different dataframes and need to merge them together based on the date column. If I only had two dataframes, I could use `df1.merge(df2, on='date')`, to do it with three dataframes, I use `df1....

mapping values are not allowed in this context

I'm a novice regarding YAML format and kubernetes. The following is a file. ``` --- apiVersion: extensions/v1beta1 kind: Deployment metadata: labels: name: prometheus-deployment name: prome...

3 Nov at 05:12

Difference between DispatchQueue.main.async and DispatchQueue.main.sync

I have been using `DispatchQueue.main.async` for a long time to perform UI related operations.

 Swift provides both `DispatchQueue.main.async` and `DispatchQueue.main.sync`, and both are performed o...

Graph API - Insufficient privileges to complete the operation

When trying to access the Graph Service Client using I am receiving the error: > Code: Authorization_RequestDenied Message: Insufficient privileges to complete the operation. After researching this e...

SharePointOnlineCredentials Missing or not found

I have added Sharepoint reference in my project. Even after adding reference, it is showing: > SharePointOnlineCredentials Missing or not found. Can anyone suggest a solution?

5 Jun at 15:16

Room - Schema export directory is not provided to the annotation processor so we cannot export the schema

I am using Android Database Component Room I've configured everything, but when I compile, Android Studio gives me this warning: > Schema export directory is not provided to the annotation processor...

2 Jan at 06:34