Unable to get output on Browser - .NET Core 3.1 Visual Studio 2019 - asp.net-web-api

I am running a Web API on Visual Studio 2019 - .Net Core 3.1 application where I am trying to display data from database SQL Server. I am not getting any errors or warnings, yet when I run it I get output on browser:
This Site Can't be Loaded. The connection was reset.
Other times, I get message:"Unable to connect to IIS Web Server"
I have added the packages Microsoft.EntityFrameworkCore,Core.Design,Core,Tools & Core.SQLServer. Am I missing any packages that I must add? This problem is with the connection to browser right?
This is a screenshot of my debug page

Related

Visual Studio 2012 'Publish Profile' to Windows Server 2008 - 'Destination not compatible' error

I am deploying a website form Visual studio 2012 to a Windows Web Server 2008 R2.
I can connect to Web Deploy fine - though I get this error:
1>(27/05/2013 21:03:29) An error occurred when the request was processed on the remote computer.
1>Source (appHostConfig=Default Web Site/myAppMVC4) and destination (appHostConfig=myapp.com) are not compatible for the given operation.
1>Publish failed to deploy.
I fixed this by right clicking the project (not solution) - clicking Package/Publish Web and deselecting 'Include IIS settings as configured in IIS'
Now works fine.
Maybe this is because I'm using IIS 8 on Windows 8 locally - and IIS 7 on Windows Server 2008?

Unable to start debugging on the web server after installing SharePoint

Visual studio 2010 was debugging fine on Win 7 , 64-bit machine. after installing sharepoint foundation 2010. SP site r working fine. but mvc, aspnet projects showing follwoing error
Unable to start debugging on the web server. the web server cound lnot find the requested resource.
thanks,
When SharePoint is installed the default web site in IIS is replaced by the SharePoint default site. Create a whole new website (and also an application pool preferrably) for yourself in IIS and deploy your code there and try debugging it. It should work.
From my past experience you cannot use an MVC template on a sharepoint environment (i.e. sharepoint iis site)
There are a few add-ons and customizations you can do, but their quite tedious.

Visual Studio 2010 published web site returns "Could not load assembly App_Web_xxxxxx.dll"

I am working on client's application in which we have two servers - development server and testing server. We first develop applications on development server and then publish it and host it on test server for client testing.
Testing server has Microsoft .NET framework 3.5 SP1. On development we have Visual Studio 2010.
We publish the website on development server using VS 2010 and then copy that folder to testing server and host it on its IIS.
Whenever we try access any aspx page of site hosted on testing server, we get error:
Could not load assembly App_Web_xxxxxx.dll". Make sure it is compiled before accessing the page
What can I do to resolve this?
This could be due to a lot of reasons.
I would start by trying one of the following things..
Make sure your IIS Site has the correct .net version specified - same as your application
Make sure you have all the required .net components installed in windows features (control panetl)
Look at event viewer for more errors and post it here
OK guys here is the solution.
Since my testing server is having Microsoft .NET framework 3.5 so on the development server while publishing from VS 2010, I have to choose target framework as 3.5.
Do this:
Right click web site -> Property Page -> Build -> Change the target framework.
After doing this setting, publish the web site again.

Cannot start debugger on Visual Studio 2010 (F5) However, ' attach to process' does work (slow). How to fix?

The environment:
Clean (new) install of Windows 7 64bit.
Clean (new) install of Visual Studio 2010 Professional (10.0.30319.1).
Windows Update is up to date.
The problem:
I cannot start the debugger on Visual Studio 2010 (hit F5): 'Unable to start debugging on the web server. Unable to connect to the web server. Verify that the web server is running and that incomming HTTP requests are not blocked by a firewall.'
However, 'attach to process' (what I usually do) does work, but it is painfully slow to start (Visual Studio 'thinks' a lot of time before the debugging is actually enabled).
On the same hardware, running VS 2008 on good old Windows XP (32bits), this problem never happened.
Trying to debug a site running under the ASP.NET Development Server also fails: 'Unable to connect to ASP.NET Development Server.'.
There are plenty of web pages about these errors (many very outdated and does not apply to my environment), none of them worked for me.
Notes:
No matter if I run Visual Studio as Administrator or not. The problem is
the same.
The problem happens even when running a brand new blank IIS web site, either created as 'localhost/something' or 'sample.local'.
If I create a 'File System' web site (to try ASP.NET Development Server), when I hit F5, the server starts, but after a long wait Visual Studio says 'Unable to connect to ASP.NET Development Server.'
The 'hosts' file has an explicit 127.0.0.1 entry for 'localhost' and for 'sample.local'
It's the same problem either running .NET 2.0 or 4.0.
It's the same either configuring the application pool with or without 'Enable 32-Bit Applications' true or false.
It's the same either configuring the application pool is classic or integrated mode.
In a desperate attempt, I've added all the IIS 6.0 legacy 'features' stuff (not needed!) and doesn't helped at all.
I don't now what else I can try.
Thanks.
OMG!, I'm so stupid. The most oblivious thing was truly wrong. There was a wrong rule in the firewall. Therefore, even being in 'interactive mode' (as it is was always set), the connection was denied.

IIS 7.5 Invalid authentication headers 401.2 when viewing site in browser

I have a Visual Studio 2010 project that is using Forms Authentiation. It runs fine from within Cassini (visual studio systray IIS, aka pressing F5). I'm using MVC2.
I created a website in IIS 7.5 (on my Windows 7 machine)
then pointed the physical directory at my Visual Studio project file
Enabled only Forms Authentication in IIS
Keep receiving this error:
HTTP Error 401.2 - Unauthorized
You are not authorized to view this page due to invalid authentication headers.
PS: I didn't use the Create Virtual Directory option in Visual studio, since I need host headers for what i'm doing, so a dedicated IIS website.
Follow the steps in this link
Error message when you try to visit a Web page that is hosted on IIS 7.0: "HTTP Error 401.2 - Unauthorized"
It is meant for IIS 7.0, but works for IIS 7.5 too.
See if this helps.
Fix 401.1 Error with Integrated Authentication on local machine

Resources