ASP.NET 5 MVC 6 EF7 CODE FIRST is not connecting to SQL database from IIS. Works locally fine - asp.net-mvc

With poor documentation from Microsoft (site says still working...forever), I completed a web application with ASP.NET 4.5.2, MVC 6 (ASP.NET 5), EF7 -Code First, Angular JS in Visial Studio 2015. This is working fine locally including user registration- that is it is inserting data to SQL database.
However, when I published to File System & ran through IIS, database is not getting created automatically nor data got inserted(if database already existed)- The error just says
'An error occurred while processing your request.'
when trying to login or while registering user.
I did not have 'Databases' section in publish web option of Visual Studio 2015.
I just need this connectivity to database. Please help to resolve as this issue is sure to be faced by everyone.

Related

How to solve database missing issue, when deploying ASP.NET MVC project to Azure?

I use database first approach in this web app. When I run the project on my local device, it is perfect.
After I publish the web app to Azure, and click the page displayed data, it returns an error page:

Published site to Windows 2012 Getting An error occurred while processing your request

I created an ASP.NET MVC (ASP>NET Wen Application.net Framework)site using Visual Studio 2019. All worked fine on my Windows 10 using IIS Express.
I then published it to a Windows 2012 Server-IIS. It seems the _Layout page is OK but every page (all have a sql connection - sql on a different server) I get the message Error.
This issue seems to be fixed in debugging by changing the Document Type to 10?
Am I missing some settings in IIS? What other information would be useful in troubleshooting this?

Connection to Domino Notes Databse using COM failed on IIS

I have created one application using MVC5 to connect to Notes database using COM interop domino dll. It works fine on my local but doesn't works through IIS of my computer. It gives login view but failed to connect to database and gives an
An error occurred while processing your request.
So I think there is a database connectivity problem with notes database. Is there any difference between accessing database using local and IIS? I haven't changed anything for IIS, just configure it to run the mvc application.
I am using 64bit OS.
Any idea why I can't connect to notes database using IIS?

MVC 3 Project Deployment

I´m trying to deploy an MVC 3 project to my server runing IIS 7.
I tried creating a package with VS2010. The resulting zip-file I moved to the server and imported this to the IIS7. This is going well so far. I can also open the loginpage in the browser, but when logging-in (Database query for checking login data ) there comes a message "Sorry, an error occurred while processing your request."
How do I have to deploy? Are there other ways? I manage the database connection via a dll. I also tried to connect to localhost but this didn´t work either.
Thanks
http://www.iwantmymvc.com/2011-03-23-bin-deploy-aspnet-mvc-3-visual-studio

Routing problem with particular controller name using ASP.NET MVC 1 in IIS 7

I have joined a team developing an ASP.NET MVC version 1 application. I run this app on my local machine using IIS version 7.5. My operating system is Windows Server 2008 R2 Enterprise Edition. I use Visual Studio 2008 SP1 for development.
One of the controllers in this app is called ReportsController. The route table entries for this controller use 'Reports' as the controller name part. The problem I have is that, using IIS 7.5 on my local machine, I simply cannot access any of the Reports action methods. If I try to access, say, '/Reports/Index' from Chrome or Firefox, I get a 401 Unauthorized response (as seen using Fiddler) and the browser displays its username/password entry dialog.
Please note the following:
All other non-Report pages in the application work correctly.
If I add a breakpoint to Application_BeginRequest, it is not hit when requesting a Reports page.
If I change the Reports routing entries in the route table registration code so that I have to access paths like '/Reportss/Index' (note the extra 's') then these Reports pages work correctly.
I have tried deleting then recreating my Web application in IIS.
The Reports pages work fine if I run the application using the Visual Studio 2008 development server (Cassini).
There is no directory called Reports in the application directory.
The Reports pages work correctly on our UAT environment, also under IIS 7.5.
I have reviewed my IIS setting several times, including comparing them with those on UAT, and I can't see a problem.
While I can use Cassini to access the Reports pages, I would really like to understand what is causing this issue.
If you have Reporting Services installed on your machine. try to create a new web site and use it. If you have SSRS installed on your machine it uses /reports for hosting reports.
I have had problems using the directory name 'Reports' at the root of a .net 2.0 website on IIS 7.5. It generates a 503 Error, indicating that there is an error at the system level before IIS tries to serve the page. I am not sure if reporting services is installed on my server. I just changed the directory name, all links and everything worked.
I have the exact same issue in my MVC Application with reporting services installed on the same server where code was deployed. I have changed the Reporting Manager URL in "SQL Server Reporting Services Configuration" which was hostName/Reports and assigned a new name i.e. SSRSReports so the virtual directory is now hostName/SSRSReports.
Now my application as well as SSRS Reports are working as expected.

Resources