Skip to content


How to show current login User details in profile using ASP.NET MVC

I want to show user details on User Profile using Session but it is not working any other way kindly suggest me, I’m using ASP.NET MVC. Login class: Dashboard controller: Screenshot of output: Answer When you use a session, that session is available throughout the site based on how long you have given it in the web config file. And

Datatables don’t load content of database

I’m trying to load users from a table in my database using datatables( but the page is not loading anything at all. I’m getting these errors when I open the console [1]: I loaded the js and css here in this order: [uncaught ReferenceError: jQuery is not defined at dataTables.bootstrap.min.js:5 at dataTables.bootstrap.min.js:5][1] /> Answer if the page is not

How to connect sql Database with in Asp.Net Core Mvc 5.0?

I can not find where am i missing. my code like this ; users.cs : } usersAccessLayer.cs ; appsettings.json And finally i got this error; An unhandled exception occurred while processing the request. NullReferenceException: Object reference not set to an instance of an object. Adonet_Sql.Models.users..ctor() in users.cs, line 14 Adonet_Sql.Models.users..ctor() in users.cs bla bla. Answer ConfigurationManager.ConnectionStrings[“DefaultConnection”].ConnectionString; is for .net Core

Find rows that have the same value on a column in

I have an issue I want to translate this SQL query int there is a relationship between student table and teacher table many to many and I want to display students that have more than one teacher and that what I trying to do in Answer You can try out both ways. Using Lambda Expressions Using SQL like

Parameters in ASP.NET MVC to create a PDF

I have a particular problem, I am working with ASP.NET MVC in C# and SQL Server. The idea is that on the main screen you see a text box and a button, entering a number that brings us our data. By bringing that data, the person can choose whether they want to see if that data in a PDF. But,