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

An exception occurred while iterating over the results of a query for context...

I am working in a project using generic repository.This is my existing repository.namespace OnlineLearning.Repository { public interface IRepository<TModel> where TModel : class, IEntity {...

View Article


Want to display edit link Button in front of Gridview

Hlo Professionals!I want to display edit link button in front of gridview and also when i click on edit gridview row to be display in above textboxes.here is my codeWeb design<div><%@ Page...

View Article


How to handle data in resource files programmatically?

HiI'm totally new at multilingual apps. I've applied this topic for multilingual core 2.1 mvc web app....

View Article

redirect to login page after session timeout

Hi,I have set up the application to not be usable after a session time out:Startup.cspublicvoid ConfigureServices(IServiceCollection services){     services = configureMiniProfiler(services);...

View Article

HttpClient and Core

I am trying to get an image size from a web site using HttpClient on Core Ver2.0.I am doing :private static readonly string browserVer = "User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64)...

View Article


RestAPI return fields under sppecific condition

I have a class which I return as per requestpublic class OutputModel { public string Id { get; set; } public int Status{ get; set; } public int Error{ get; set; } }I want to return the Error property...

View Article

Unable to cast object of type 'System.Byte' to type 'System.Int32' problems

I have a .NetCore Blazor App, morphed from the stock weather forecast service that comes with it, whereas I have players who log their play info, but once a player logs in and wants to look at their...

View Article

Date control is not showing value from model

I have this code [DataType(DataType.Date)] [DisplayFormat(DataFormatString = "{0:dd/MM/yyyy}",ApplyFormatInEditMode = true)] [Required(ErrorMessage = "Captura este campo")] public DateTime? BirthDate {...

View Article


Field not rendering across 3 table relationship

Hi So I am using ASP.NET Core 2.2 with EF Core with SQL Server DB. I got a database that looks like this. So I have 3 tables in SQL Server. tblJobs, tblResults and tblProblems and others I omitted as...

View Article


Controller export to .csv failed for IE

Hi,Why IE can't pop up the file csv to save?//Download the CSV file.Response.Clear();Response.Buffer =true;Response.AddHeader("content-disposition","attachment; filename="+ module.Replace(" ","_")...

View Article

Unable to Access ViewData to another Action result

Hi All,I am unable to Access ViewData["RegionData"] to another actionResult, Below is my code using ASP.NET Core 3.1 MVC [Route("DataUpload/[Controller]/{id}")] public async Task<IActionResult>...

View Article

Azure AD Authentication Back Button Issues

I am trying to resolve an issue with ASP.NET in regards to how it facilitates authentication against Azure AD.  Overall I am able to successfully authenticate, however there are seemingly unavoidable...

View Article

Validation not showing in Jquery Modal Popup

I am using .net core but my validation is not showing in my popup I use the same dialog for new and edit so need to be carefull it works the same<div><form id="myForm"><div...

View Article


Cannot retrieve image which has http in its url.

Hi, guys, I'm new to asp.net core. I want to show some images on my site but the images are over unsecured connection for examplehttp://image.png . If I write this absolute link inside image tag...

View Article

Return Not Found From Controller

Hi, in startup.cs i use this code to manage errors (404 , 500 , ...) and its worked correctly when i search a action thats not found and go to error action ....

View Article


Create Customize NotFound Method

Hi  i want create methods for my customize example :  return NotFound();i write this method but i cant call it in other controller just i cant use in own  controller  public IActionResult NotFound1() {...

View Article

Difference in running Asp.net Core app in docker vs iis

I just created a sample api project and ran it inside of a container using docker commands and even created a custom image of the sample app. I am a beginner and am a bit confused right now as how is...

View Article


Solving the problem of slow query in my efcore.

So I built an inventory application. I occasionally experience slow queries when retrieving data. This got me worried cos the client is complaining.So I would paste one of the major query returning...

View Article

List inside another list

Hi,How to pass a list of data inside another list in the DAL o the stored procedure in c#

View Article

how can I add important master data if not record there while running the...

HiHow  to insert the  record automatically into the master tables automatically  if there is no record while running the application.  At the moment I am doing given way but it only works while running...

View Article
Browsing all 9386 articles
Browse latest View live


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