Disable Button in Angular 2
I want if the input 'Contract type' is empty, the button 'Save' is not clickable Save button: ``` <div class="col-md-4"> <cic-textbox [control]="formGroup.get('contractType')"></cic-textbox...
- Modified
- 18 Mar at 10:56
How to remove nbf claim
have been looking an answer for this from everywhere, but can't seem to find one that applies to me. The thing is i'm trying to construct a JWT token with ASP.NET in c#. The problem i'm running in to ...
ValueError: could not broadcast input array from shape (224,224,3) into shape (224,224)
I have a list say, temp_list with following properties : ``` len(temp_list) = 9260 temp_list[0].shape = (224,224,3) ``` Now, when I am converting into numpy array, ``` x = np.array(temp_list...
Why is `this` not available in C# 6.0 Auto-Property Initialization?
I have the following code class: ``` public class Foo { public Nested Bar { get; } = new Nested(this); public class Nested { public Nested(Foo foo) { foo.DoSo...
- Modified
- 16 May at 12:4
ASP.NET Core: JSON Configuration GetSection returns null
I have a file `appsettings.json` that looks like this: ``` { "MyConfig": { "ConfigA": "value", "ConfigB": "value" } } ``` In my `Startup.cs` I'm building my `IConfiguration`...
- Modified
- 15 May at 07:1
File naming conventions in reactJS?
Recently, I have started learning ReactJS. The only thing that confuses me is naming and in the React app directory. - To name component files, some people follow `TitleCase.js` and some follow `cam...
- Modified
- 11 Jan at 10:31
Cannot find AddMvc() in IServiceCollection in Visual Studio 2017
I have created a brand new asp.net core application. I have added the mvc Nuget package yet I am getting the below error. Microsoft.AspNetCore.Mvc.Core 1.1.3 > 'IServiceCollection' does not contain a ...
- Modified
- 14 Aug at 17:19
Service Stack API - System.InvalidOperationException - ServiceStack.ServiceStackHost.OnEndRequest(IRequest request)
We are using Service Stack Web API for our web application. On prod server all the functionalities will work but for every request an error is generated as below when we make a request to server. ``...
- Modified
- 14 May at 23:51
ASP .NET CORE could not find file or assembly with custom assembly
I've ran into a weird problem. I basically have my own web-stack for .NET-core which I've built into a few .dlls, and I want to reference these from another ASP CORE-solution. VS seems to find the a...
- Modified
- 14 May at 20:53
Google API: Not a valid origin for the client: url has not been whitelisted for client ID "ID"
I need help. I don't found an answer to my question. I tried googling and I tried asking on other sides but I never found an answer. I'm working with the google API (Youtube data API) and I use the ex...
- Modified
- 20 Jun at 09:12
Environment.MachineName equivalent for .NET Standard 1.4
I am creating a class library that will be used in a WPF project and a .NET Core project. I am trying to get the name of the machine using my application. In both .NET Core and the WPF application I ...
- Modified
- 23 May at 11:47
ASP.NET Core 2.0 Preview 1: How to set up Cookie Authentication with custom login path
In ASP.NET Core 2.0 the .UseAuthentication() middleware has a breaking change that no longer allows the [old syntax mentioned here](https://learn.microsoft.com/en-us/aspnet/core/security/authenticatio...
- Modified
- 14 Aug at 18:53
Unit Tests failing when I Run All Tests but pass when I Debug
I'm using NUnit3 in Visual Studio 2017 and doing TDD. Something really strange is happening since I updated my code to make my latest test pass. Now, 3 of my other tests are failing when I click Run ...
- Modified
- 13 May at 22:17
How to adapt IObjectContextAdapter from EF 6 to EF Core
I am trying to port this class to EF core: [https://github.com/mehdime/DbContextScope/blob/master/Mehdime.Entity/Implementations/DbContextScope.cs](https://github.com/mehdime/DbContextScope/blob/mast...
- Modified
- 14 May at 02:21
Convert float64 column to int64 in Pandas
I tried to convert a column from data type `float64` to `int64` using: ``` df['column name'].astype(int64) ``` but got an error: > NameError: name 'int64' is not defined The column has number of ...
React-router and nginx
I am transitioning my react app from webpack-dev-server to nginx. When I go to the root url "localhost:8080/login" I simply get a 404 and in my nginx log I see that it is trying to get: ``` my-nginx...
- Modified
- 13 May at 10:14
What is analog for HttpListener in .NET Core
I'm porting application from .NET 4 to .NET Core and can't find analog for HttpListener class ``` Error CS0246 The type or namespace name 'HttpListener' could not be found (are you missing a using...
- Modified
- 15 May at 11:47
How to ignore null values for all source members during mapping in Automapper 6?
I've been looking everywhere: stackoverflow, automapper documentation, internets and just couldn't find any info on this one, even tho this seems to be a very common problem. My mapping: ``` CreateM...
- Modified
- 23 May at 10:31
.NET 4.7 returning Tuples and nullable values
Ok lets say I have this simple program in .NET 4.6: ``` using System; using System.Threading.Tasks; namespace ConsoleApp1 { class Program { static async void Main() { ...
Scroll to element on click in Angular 4
I want to be able to scroll to a target when a button is pressed. I was thinking something like this. ``` <button (click)="scroll(#target)">Button</button> ``` And in my `component.ts` a method like....
- Modified
- 25 Jun at 22:33
Serialize JSON using DataAnnotation to apply decimal formatting rules
We have several complex classes with a variety of decimal (and other) properties. Of the dozens of decimal properties, they all fall under 3 specific formatting rules: 1. Leading zero, one decimal p...
- Modified
- 12 May at 19:48
Get YAML for deployed Kubernetes services?
I am trying to deploy my app to running in . The app can be found at: [https://github.com/Industrial/docker-znc](https://github.com/Industrial/docker-znc). The is built into an image on . I have ...
- Modified
- 9 Dec at 05:51
C# Display text on the taskbar | Windows 10
I want to display a text in the taskbar like the NetSpeedMonitor program . I thought about how Windows did that with der Date and Time display, but I couldn't find any answer. I want to do this with C...
- Modified
- 12 May at 15:55
Servicestack Multi Tenancy
Does the [Servicestack](http://docs.servicestack.net/) support the Single Deployment with Single Database multi-tenancy method? [The documentation says only about multiple databases](http://docs.servi...
- Modified
- 12 May at 15:43
Using R.NET.Community in .NET Core 2.0 Preview 1
For a while, I've been hoping to use [R.NET.Community](https://www.nuget.org/packages/R.NET.Community/) in a .NET Core app. Obviously though with the NuGet package not having been ported to .NET Core,...