How to return data from promise

I need to get the `response.data` out of the promise so it can be returned by the enclosing function. I know, I probably can't do it the way I've coded it because of normal JavaScript scope. Is there ...

29 May at 08:34

How to tell Application Insights to ignore 404 responses

ApplicationInsights has recently started mailing me a Weekly Telemetry Report. My problem is that it tells me that I have a bunch of Failed Requests, Failed Dependencies, and Exceptions, but when I c...

24 Oct at 18:47

Use MemoryStream and ZipArchive to return zip file to client in asp.net web api

I am trying to return zip file from asp.net web api to client using The following Code: ``` private byte[] CreateZip(string data) { using (var ms = new MemoryStream()) { using (var ar...

How do I solve a "view not found" exception in asp.net core mvc project

I'm trying to create a ASP.NET Core MVC test app running on OSX using VS Code. I'm getting a 'view not found' exception when accessing the default Home/index (or any other views I tried). This is th...

16 Oct at 21:57

Is there default way to get first task that finished successfully?

Lets say that i have a couple of tasks: ``` void Sample(IEnumerable<int> someInts) { var taskList = someInts.Select(x => DownloadSomeString(x)); } async Task<string> DownloadSomeString(int x) {....

Entity Framework: The context is being used in Code First mode with code that was generated from an EDMX file

I am developing an WPF application with EF 6 database first approach, I am have 1 project in my solutions, if i run my project this error always appear. [http://go.microsoft.com/fwlink/?LinkId=394715...

Get SQL code from an Entity Framework Core IQueryable<T>

I am using Entity Framework Core and I need to see which SQL code is being generated. In previous versions of Entity Framework I could use the following: ``` string sql = ((System.Data.Objects.Object...

3 Feb at 09:16

Compiling and running code at runtime in .NET Core 1.0

Is it possible to compile and run C# code at runtime in the new .NET Core (better .NET Standard Platform)? I have seen some examples (.NET Framework), but they used NuGet packages that are not compati...

10 Jul at 20:15

run single *.cs script from command line

Is there at last a easy way to execute c# script file from command line? I saw that [discussion on github](https://github.com/dotnet/cli/issues/59) and according to this thread i think `dotnet run T...

30 May at 13:6

Visual Studio Code, #include <stdio.h> saying "Add include path to settings"

I'm trying to build C/C++ in Visual Studio Code. I installed C/C++ and all the relevant extensions. ``` #include <stdio.h> int main() { printf("Test C now\n"); return 0; } ``` But there's a...

25 Aug at 21:51

How to install mcrypt extension in xampp

how to install mcrypt in xampp on windows? My PHP Version 7.0.5 and xampp pack have not so how can i install mcrypt on xampp ?

30 May at 09:39

react-router getting this.props.location in child components

As I understand `<Route path="/" component={App} />` will gives `App` routing-related props like `location` and `params`. If my `App` component has many nested child components, how do I get the child...

23 Dec at 14:45

How to create an associative array in JavaScript literal notation

I understand that there are no in JavaScript, only . However I can create an with string keys using like this: ``` var myArray = []; myArray['a'] = 200; myArray['b'] = 300; console.log(myArray); //...

11 Jul at 06:14

Converting Pandas dataframe into Spark dataframe error

I'm trying to convert Pandas DF into Spark one. DF head: ``` 10000001,1,0,1,12:35,OK,10002,1,0,9,f,NA,24,24,0,3,9,0,0,1,1,0,0,4,543 10000001,2,0,1,12:36,OK,10002,1,0,9,f,NA,24,24,0,3,9,2,1,1,3,1,3,2,...

What is the purpose of remarks tag in c#

I understand that remarks tag is used to provide additional information about the class but it is not displayed in intellisense while hovering / calling that class. I would like to know Where exactly ...

29 May at 07:29

Elvis (?.) Extension Method in C# 5.0

Is it possible to create some extension method in C# 5.0 to give the same results as the C# 6.0 Elvis (?.) operator? For example: ``` //C# 6.0 way var g1 = parent?.child?.child?.child; if (g1 != nu...

29 May at 08:34

Visual Studio not showing IntelliSense descriptions anymore

Since a month ago, my VS doesn't seem to want to display the summary info in tooltips for any system methods or classes when I hover them with my mouse. I had ReSharper installed and started noticing...

no target device found android studio 2.1.1

i'm using in ubuntu 14.04.Now my question is,i want to run the program through my phone without emulator. so i chose the target as usb device but whenever i run this,below mentioned error is rasing. ...

AccessDeniedException: User is not authorized to perform: lambda:InvokeFunction

I'm trying to invoke a lambda function from node. ``` var aws = require('aws-sdk'); var lambda = new aws.Lambda({ accessKeyId: 'id', secretAccessKey: 'key', region: 'us-west-2' }); lambda...

C# readonly vs Get

Are there any differences between the readonly modifier and get-only properties? Example: ``` public class GetOnly { public string MyProp { get; } } public class ReadOnly { public readonly ...

20 Jun at 20:18

Are the ParallelExtensions "Extras" still of value?

The [Task Parallels Extras extension](http://blogs.msdn.com/b/pfxteam/archive/2010/04/04/9990342.aspx) was published in 2010, and since then no updates have been released. I published this code as a ...

Entity Framework Core RC2 table name pluralization

Is there a way to do what this code did in EF Core RC 2? ``` protected override void OnModelCreating(ModelBuilder modelBuilder) { modelBuilder.Conventions.Remove<PluralizingTableNameConventio...

Incompatible wire encryption levels requested on client and server with Firebird ado.net provider

I am testing the connection firebird 3 using C #. The version of what I'm used is the latest : Firebird ADO.NET Provider 5.0. But when you make the connection , the error occurs "Incompatible wire enc...

Are .NET threads different from operating system threads?

1. Are .NET threads lightweight user-mode threads or are they kernel-mode operating system threads? 2. Also, sparing SQL Server, is there a one-to-one correspondence between a .NET thread an an opera...

27 May at 20:15

CreateType missing from TypeBuilder. How to port this?

Trying to port an application from .net 4.5 to .net core for a client. I'm noticing that CreateType is no longer part of TypeBuilder. I've searched through multiple of the new reflection libs with no ...

1 Oct at 18:24