Quantcast
Channel: ASP.NET Core
Browsing all 9386 articles
Browse latest View live

Creating a core 1.0.0 app

I am trying to get an empty Core app running. I created an empty core app from VS 2015. Made no modifications. when I build, I get and error restoring package. This is from the output window.  Am I...

View Article


Add Entity Framework to Asp.net Core site

Hello.It is such that I am working on Asp.net Core. I have tried to examine the options available for getting Entity Framework on my site.My question is: - How do I add Entity Framework for my...

View Article


How to get reference of business.Entity class in mvc

Hi I have 3 layer app.1)Business.Entity class2)EntityFramework.Dbconnection.3)My_domain_mvci want to get ref of my entity class in dbconnection  so how can i get all class file in my dbcontext class...

View Article

Can not find compilation library location for package

Hi,I have created a nuget package via pack command and pushed the package to intrernal nuget server. So far so good. I add a reference in my other project to the package by "Manage nuget packages". It...

View Article

How to include SMS Gateway in asp.net core project?

I am trying to create a asp.net core web application that sends sms to mobile, when mob is given. I have tried using CM.SMS.Gateway, and Twilio. Both are showing errors not compatible. 

View Article


Controllers in dynamic assembly

Hi. I am trying to create some dynamic convention based API controllers like so:// Create some controllers via Reflection.Emit inside dynamic assemblyvar assembly =...

View Article

Diagnosing Random 500 0 with Core site in IIS 8

I have a Core MVC site that I'm developing and publishing to IIS 8 on Win 2012.  The siteworks fine 99% of the time, but occasionally starts throwing 500 0 responses until I restart the site in IIS.The...

View Article

How read multiple csv text files and convert into json ?

Hi ALLI am working on .net core and i want to reall multiple csv text files and covert into json string .How can i achieve this into .net core ?Thanks.

View Article


Problem with MVC Movie Store tutorial using VS 2015

I am trying to do the MVC movie store tutorial using Visual Studio 2015.  So I open VS 2015 and click new project.  The tutorial says I should have an option, .Net Core under Visual C#.  But I do not...

View Article


Publishing doesn't show the "Entity Framework Migrations"

My project used to work perfectly for .NET Core 1.0, but moving to 1.1 is causing me days of headache!!  I've been usingMicrosoft Azure for publishing and hadn't had too many problems.I think I'm down...

View Article

Routing - the missing application

I have distributed my first core system to our IIS server for testing and I have found that I'm missing a piece of my context.  The system has been loaded into an IIS application, thus the url...

View Article

Creating a Role

HiI am working from the ASP.NET Core template with Individual User Accounts.And I am trying to create a new Role. My code below gives and error on the CreateAsync line...Object not set to an instance...

View Article

Why can't I develop in VS 2015 and deploy to Linux.

Hi, I built a small web api application in VS 2015, and tried to run it on Ubuntu but I get the errorerror MSB4019: The imported project...

View Article


Exception Filters returning an empty body in asp.net-core 1.1

The following Exception Filter redirects exceptions to my specific error page:[AttributeUsage(AttributeTargets.Method | AttributeTargets.Class, AllowMultiple = false)] public class...

View Article

Middleware create requestcode 500 allthroug i set 401

Hallo,i create a middleware for my API Requests. When i set 401 i get a 500 server error. i think, the middleware steps to the next middleware (identity). if i set the 400 code, i will request the...

View Article


How to get ViewComponent as string the the .cshtml view?

In Asp.Net vNEXT (the older version of Asp.Net Core), i could get the ViewComponent drawed as a string by calling Component.Invoke(XXX).ToString() or something like that very easy.But now the current...

View Article

Best Practice for Versioning assemblies in solution

Hi,I have have a solution with quite a few dotnetcore projects. I need to set\increment the version as part of our build. Each project should have the same version.In previous versions of .net I had a...

View Article


How do I mock the DocumentClientException that the Azure DocumentDB client...

Hi, We are porting an existing .Net 452 application which uses the Microsoft.Azure.DocumentDB package to ASP .Net Core. In the existing version we were using the approach mentioned @...

View Article

How to specify a custom build step in xproj for ASP.NET Core?

I have an ASP.NET Core server providing server-side ReSTful API methods to an Ember JS client. I keep and build the client separately, and target the results into the wwwroot of the server project....

View Article

How to log response using middleware in aspnetcore Web API

Hi,I'm trying to log the response via the middleware of an aspnetcore Web API.The only code I've been able to find to do this is the followingpublicclassLogResponseMiddleware{privatereadonly...

View Article
Browsing all 9386 articles
Browse latest View live