Using a C# 7 tuple in an ASP.NET Core Web API Controller
Do you know why this works: ``` public struct UserNameAndPassword { public string username; public string password; } [HttpPost] public IActionResult Create([FromBody]UserNameAndPassword use...
- Modified
- 20 Jan at 15:37
Understanding async / await and Task.Run()
I thought I understood `async`/`await` and `Task.Run()` quite well until I came upon this issue: I'm programming a Xamarin.Android app using a `RecyclerView` with a `ViewAdapter`. In my Method, I tr...
- Modified
- 8 May at 08:33
Get text from inside google chrome using my c# app
I am writing a small app that will among other things expand shortcuts into full text while typing. example: the user writes "BNN" somewhere and presses the relevant keyboard combination, the app woul...
- Modified
- 24 Apr at 13:34
Using LINQ expressions in Visual Studio's Watch window
I have a byte[] variable in program, e.g.: ``` byte[] myByteArray = new byte[] { 0xF0, 0x0F }; ``` When debugging this program, I wanted to display the byte array content as individual hexadecimal ...
- Modified
- 24 Apr at 08:24
Importing JSON file in TypeScript
I have a `JSON` file that looks like following: ``` { "primaryBright": "#2DC6FB", "primaryMain": "#05B4F0", "primaryDarker": "#04A1D7", "primaryDarkest": "#048FBE", "seconda...
- Modified
- 1 Apr at 16:31
Create a rounded button / button with border-radius in Flutter
I'm currently developing an Android app in Flutter. How can I add a rounded button?
- Modified
- 28 Feb at 16:56
Adding property to a json object in C#
I'm trying to add a property to a json object, which are not root of the json. example is below. after the operation, i want the json file to look like below. I have gotten to the point where I can ac...
How to truly avoid multiple buttons being clicked at the same time in Xamarin.Forms?
I am using multiple buttons in a view, and each button leads to its own popup page. While clicking multiple button simultaneously, it goes to different popup pages at a time. I created a sample cont...
- Modified
- 3 May at 13:10
ServiceStack OrmLite - Elegant way to handle SQL Server Connection Drops
We are currently using ORMLite and it is working really well. One of the places that we are using it is for running large batch processes. These processes run a single large batch all within a single...
- Modified
- 23 Apr at 13:54
Accessing dbContext in a C# console application
I have tried to figure this out, but I am stuck. I have a Net Core 2 application with Service/Repo/Api/Angular layers - but now I want to 'bolt on' a console application and access all the goodies I ...
- Modified
- 23 Apr at 21:48
Explicit Loading nested related models in Entity Framework
I'm working on an ASP.NET MVC5 project using EF6. I have 3 models: user, role and permission. The relation between user and role is many to many. The relation between role and permission is many to m...
- Modified
- 22 Apr at 16:41
Axios handling errors
I'm trying to understand javascript promises better with Axios. What I pretend is to handle all errors in Request.js and only call the request function from anywhere without having to use `catch()`. ...
- Modified
- 22 Apr at 15:45
PIP 10.0.1 - Warning "Consider adding this directory to PATH or..."
``` The script flake8.exe is installed in 'c:\users\me\appdata\local\programs\python\python36-32\Scripts' which is not on PATH. Consider adding this directory to PATH or, if you prefer to suppress thi...
How to develop Android app completely using python?
I would like to develop a (rather simple) android app to be distributed via Play Store. I would like to do so completely in python. However, the online research hasn't quite enlightened me: most comme...
C# HttpClient refresh token strategy
Since Microsoft [recommends](https://learn.microsoft.com/en-us/dotnet/api/system.net.http.httpclient?view=netframework-4.7) that the `HttpClient` be created once and reused throughout the life of a pr...
- Modified
- 21 Apr at 12:9
Couchbase Lite 2 + JsonConvert
The following code sample writes a simple object to a couchbase lite (version 2) database and reads all objects afterwards. This is what you can find in the official documentation [here](https://devel...
- Modified
- 20 Apr at 20:50
phpMyAdmin on MySQL 8.0
Newer versions of phpMyAdmin solved this issue. I've successfully tested with phpMyAdmin 5.0.1 --- I have installed the MySQL 8.0 server and phpMyAdmin, but when I try to access it from the brow...
- Modified
- 19 Feb at 12:43
Blazor onchange event with select dropdown
So I have been stuck trying to get a simple onchange to fire when a select dropdown value changes. Like so: ``` <select class="form-control d-flex" onchange="(dostuff())"> @foreach (var template ...
- Modified
- 12 Aug at 21:8
How to correctly use axios params with arrays
How to add indexes to array in query string? I tried send data like this: ``` axios.get('/myController/myAction', { params: { storeIds: [1,2,3] }) ``` And I got this url: ``` http://localhost/api...
- Modified
- 20 Apr at 14:49
IDX21323 OpenIdConnectProtocolValidationContext.Nonce was null, OpenIdConnectProtocolValidatedIdToken.Payload.Nonce was not null
I'm attempting to authenticate for Azure AD and Graph for an Intranet (Based off Orchard CMS), this functions as expected on my local machine, however, when accessing what will be the production site ...
- Modified
- 23 Jun at 22:44
Dart: mapping a list (list.map)
I have a list of `String`s, e.g., ``` var moviesTitles = ['Inception', 'Heat', 'Spider Man']; ``` and wanted to use `moviesTitles.map` to convert them to a list of `Tab` `Widget`s in Flutter.
- Modified
- 20 Apr at 22:50
What System.Drawing classes count as GDI objects?
I have been having difficulties understanding which exact objects from the `System.Drawing` namespace actually contribute to the system total GDI object count. For instance, do `Matrix` objects count?...
C# method overload resolution issues in Visual Studio 2013
Having these three methods available in Rx.NET library ``` public static IObservable<TResult> Create<TResult>(Func<IObserver<TResult>, CancellationToken, Task> subscribeAsync) {...} public static IO...
How to return values from async functions using async-await from function?
How can I return the value from an async function? I tried to like this ``` const axios = require('axios'); async function getData() { const data = await axios.get('https://jsonplaceholder.typico...
- Modified
- 20 Apr at 09:45
Automapper in xUnit testing and .NET Core 2.0
I have .NET Core 2.0 Project which contains Repository pattern and xUnit testing. Now, here is some of it's code. ``` public class SchedulesController : Controller { private readonly ISchedule...
- Modified
- 20 Apr at 11:13