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

ASP.NET CORE 2: Using Correct appsettings.json Per Environment

Hi,I've found that this issue is posted all over the internet but I have not found a working resolution.  The only approach that comes close to working is setting the environment variable in a...

View Article


How to connect IBM Netezza Database in .Net Core 2.0

How to connect IBM Netezza Database in .Net Core 2.0

View Article


.Net Core + Typescript + React js integration

Hi,I am from SharePoint/.Net background. In recent past I have been using react extensively in client side SharePoint components. All the coding I have been doing in Typescript. Now I also wish to add...

View Article

What {area:exists} does ?

app.UseMvc(routes => { // Areas support routes.MapRoute( name: "areaRoute", template: "{area:exists}/{controller=Home}/{action=Index}/{id?}"); routes.MapRoute( name: "default", template:...

View Article

DbContext is getting disposed - Dependency Injection EF Core (Simple App)

Hello everyone! I've been searching for a while, but I haven't spot anything unusual... Maybe some configuration I've been missing? I'm injecting a dependency file which at the same time contains an...

View Article


Opening my ASP.NET website on another Computer

Hello I'm trying to open my ASP.NET website on another computer but I keep getting errors and in the properties it says the server state is closed.Could someone please help me figure it out?I created...

View Article

Core 2 - Ajax submit with ValidateAntiForgeryToken not working

Hi,I have this Core 2.0 project but the code below is not working if I set the ValidateAntiForgeryToken attribute.The error at browser:.XML Parsing Error: no root element foundLocation:...

View Article

Issue: Cannot insert explicit value for identity column in table 'TABLE' when...

Hi all,I have issue when insert entity.my code:public class HsiHcm { [Required] [Key] public int Id { get; set; } public string AggName { get; set; } public string SrtName { get; set; } public string...

View Article


ASPNETCORE 2.0 CORS problems

Hey guys! I have some troubles with CORS:public static IWebHost BuildWebHost(string[] args) => WebHost.CreateDefaultBuilder(args) .UseStartup<Startup>() .Build(); public Startup(IConfiguration...

View Article


Alternative for Call Context in .Net Core

All,I understand that .Net Core doesn't support Call Context. But our application uses the same and we are planning to migrate it to .Net Core. Could anyone suggest us the Alternative approach for this...

View Article

Asp.net core - website hosting on iis: page was not found (error 404) when...

I have a problem with my asp.net core 2.0 website, i want to host my website on IIS 10 locally, so i published my project to a folder, and enable IIS service then copy my website folder to...

View Article

Class Library with Entity Framework Core

Hi,Someone know where I can find any guide about how develop a Class Library Project with Entity Framework Core for .NET Core 2.0 or higger?The problem is that when we develop an asp.net core mvc...

View Article

Project

Hi  I have below line written . Using VS 2012. It is giving error The name csLogin does not exist in the current context. ClsLogin is in App_Code bool status = clsLogin.CheckIfUserCookieExist();I have...

View Article


architecture design for application user

I have an architecture design question,I am using asp core identity to manage my user auth and login, I also have a patient registry in my db and I their access to the db is optional. my question is,...

View Article

Custom Authorization in Asp.net Core

So i am new to Asp.net Core and i want to implement custom authorization layer so i can use Authorize attributes to check for roles. Here is my what i want to achieve.In my application i do not want to...

View Article


Multiple Connection Strings in ASP.net Core

Is there a way I can cycle through the connection strings in an appsettings.json file?"ConnectionStrings": {"DefaultConnection": "MyConnectionString","ConnectionString2": "MyConnectionString" }

View Article

Swagger on aspnetcore 2.0 not working

Trying to get SOME kind of swagger tooling working with my WEBAPI on ASPNETCORE 2.0 but having a lot of trouble...So I went back to an empty project and following the workflow here...

View Article


Loading MetaData from Partial Class in Aspnet Core

Hello everyone, I'm building a project in MVC template using AspNet Core.I've used Entity Framework and I've scaffolded an existing DB. Now, I want to add some Data Annotations to some classes, but I...

View Article

one-to-many relationship include and where

Hi Everyone,var products = unitOfWork.Products.GetAll() .Include(i => i.ProductDetails).Where(d=>d.ProductDetails.Any(i=>i.LanguageId==2)).ToList(); I have these two tables. I want to write...

View Article

IBM .NET Provider for .NET Core 2.0 -ERROR [42705] [IBM] SQL1013N

I am using IBM.Data.DB2.Core to connect to DB2 database from .Net core 2.0Below is the code:using (DB2Connection connection = new DB2Connection(conn)) { connection.Open();//Below error at this...

View Article
Browsing all 9386 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>