ASP .Net Page Can't Be Displayed Error - asp.net

I am having the strangest issue. My website has been working perfectly in Visual Studio 2008 until I tried to work on the website in Visual Studio 2012. Having abandoned that idea, I am now back to Visual Studio 2008 with the following problem.
Problem:
Any page inside any folder displays a "Page can't be displayed" error or similar in all browsers (IE, Firefox, Chrome, Safari) UNLESS the page is a Default.aspx page. Break points do not load for any of the pages having problems, although debugging is enabled in Web.config. There are no errors in the event viewer.
Possible reason for problem:
I tried working on the website in Visual Studio 2012. After it didn't recognize any of the imports, etc., I decided to just continue using Visual Studio 2008.
I also deleted all of the files and folders in my %temp% directory
What I've tried:
Create a new blank page in any folder to see if it will display; the page has the same error
Comment out all code on an existing non-Default.aspx page; same problem
Check the hosts file; nothing is active and other changes I've made had no effect
Browse to another page from Default.aspx; same problem "Page can't be displayed"
Checked for new AV, malware, etc. software recently installed; none installed
Created a new site on the same machine to see if new site will have the same problem. New site works just fine.
Cleared out the contents of C:\Windows\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET Files; no change
Environment:
Visual Studio 2008 on Windows 7 x64. The backend is in VB .Net
Running on the developer machine using ASP .Net Development Server
Any and all help is appreciated.
Thank you.

So, I figured it out. Essentially, I was redirecting all but the Default.aspx pages to https (inside Global.asax). While this works on the production server that has valid certs, on the development machine, all one gets is the aforementioned behavior. Thank you all for the comments and suggestions.

Had the same error.
Turning customErrors Off worked for me.
In web.config:
<customErrors mode="Off" defaultRedirect="ErrorPage.aspx" ...>

In my case, Dropbox happened to be using the same port (49210). Fixed my issue by terminating the conflicting application. Alternately, change the port under the Project's properties.

Related

My Visual Studio Web Form Site loses it's CSS and Minimisation when published

I have created an ASP.NET Web Forms Web Site in VS2013
This includes items such as WebGrease and BundleOptimisation
Everything is working perfectly locally on my machine.
But when I publish the website to the actual server, all of the CSS is not being referenced and accessing pages without the .aspx stops working (eg /dashboard instead of dashboard.aspx)
I am running IIS7.1 on the server
Any help would be fantastic. I can't find a solution to this anywhere on the internet but maybe I am typing the wrong search terms!
I found the issue after scouring through solution after solution.
You change "<'module>" to in the <'system.webServer> part of the web.config file
That gets the Rewrite working.
And set debug=true in <'compilation debug="true" targetFramework="4.5">
So that the CSS works ...
It took so long to fine!

ASP.NET pages not loading on IIS8 (Windows Server 2012)

I am trying to set up my Windows Server 2012 to run an ASP.NET website. The website can serve html pages and .svc pages, but whenever I visit an .aspx page, it will simply time out.
Error 118 (net::ERR_CONNECTION_TIMED_OUT)
If I would at least get some sort of error description, I could go from there, but I just get a timeout message, as if the server is completely unavailable, so I am stuck with this problem.
It seems the aspx pages are not loaded at all, since I've already tried drastic measures such as putting a "throw Exception" in the first line of Page_Load.
If I create a new site and put just an aspx page in there, it executes fine.
The Event Log is not showing anything in relation to this.
Does anyone have any suggestions?
Creating a new web site in IIS8 and pointing to the same folder made it work. Now the site is working fine and running code as normal.
My guess is, that if I created the website before installing all needed features, they were not part of that site. Now, after installing a new site, it contains all the current features.
It doesn't make TOO much sense, though, as the server had ASP.NET 4.5 from installation (it's Windows Server 2012).
Open up the Web Platform Installer.
Now look for IIS: ASP.NET 4.5 and install that.
I had the same problem as everyone else and nothing worked until I did that.
There is a difference between installing dotNET on your computer/server and dotNET for IIS.

Master Page cannot be loaded in C# ASP.Net publish

I am currently new to ASP.NET C# programming and have created a ASP.net Web application project in visual studio 2010, .NET 4.0. I have researched thoroughly to find a solution to my problem the last couple days but had no luck.
My issue is, debugging my project has no issues running on my local machine. I have a Site.Master page that is reference with a site.css. All my .ASPX pages run through the master site. However when i publish my website using File System
and setting my target location to my desktop, any call on a < href> tag to my default.aspx cannot load the site.master page. the error is as follows:
"The Master Page file 'Site.Master' cannot be loaded.
Correct the problem in Code View".
now i do have IIS 7.5 installed, and i have tried to create a website through the inetmgr by following various steps through google searches and videos and still have no luck. is there something specific i am missing? everything is named the same in reference to stylesheet.
In addition to WraithNath's comment, might want to ensure IIS is configured to allow ASP.NET

IIS 7 Wont Open My Aspx Files

I am new to IIS and it is annoying the hell out of me!
I have an asp.NET website that runs beautifully on visual studio 2010, so what i do, is publish the website, put the published website folder in the inetpub/wwwroot folder, connect all the dots, then in my browser i type in http://localhost:8080/A3Media/ and it brings up my index.html page. So the IIS is working correctly because it happily displays .html files. but when i try and access a .aspx file in my website. I get i weird 404 error saying the document doesnt exist. When it obviously does exist because... I checked... multiple times!
So i deducted that my IIS doesnt like .aspx files or anything to do with asp.NET.
So i make sure that i have all the asp.net modules installed by following the usual "windows features" and making sure the asp.net folder is ticked and installed, along with all the depending asp.net folders.
and my website still doesnt work.
have i missed something?
i have no idea:(
One of two options spring to mind.
Have you registered ASP.NET? aspnet_regiis.exe -i Link
cmd -> cd C:\Windows\Microsoft.NET\Framework\v4.0.30319
C:\Windows\Microsoft.NET\Framework\v4.0.30319> aspnet_regiis.exe -i
In IIS manager - Request Filtering - Is .aspx denied?
Make sure you convert your "A3Media" directory into ASP.NET Application via IIS Manager, please see Deploying ASP.NET Websites on IIS 7.0 for more details.

VS2010 - ASP.NET Configuration Won't Open

I have a standard ASP.NET project. I have created a login control on the page and now I would like to start adding the option to register as a member on my page.
My problem is that when I click "Asp.net Configuration" in the solution explorer or under the Projects tab. Nothing opens up.
I have made sure that my project is not running, the configuration window just won't open.
SOLVED! I had exactly the same problem, Firefox was my default browser, after I reset Internet Explorer as the default browser, it worked! The configuration page is (for some silly reason) a web page, and perhaps it only jives with IE.
I had the same problem, but I didn't want to keep switching from Firefox to IE to solve the issue. Digging a bit deeper, it seems the provided URL is incomplete. You need to use the following template:
http://localhost:<port>/asp.netwebadminfiles/default.aspx?applicationPhysicalPath=<projectPath>&applicationUrl=/
Hope that helps.
First check if you have an aspnetdb.mdf under the App_Data subfolder of that you previously set up the needed tables for the application services in another database.
If you haven't got these then build the solution and navigate to the page which has the login control on it. Normally ASP.NET will generate the needed database aspnetdb.mdfin the App_Data folder. Once you have that database you should be able to use the configuration which starts a web application with which you can create your users and define the roles to which they belong.
Grz, Kris.
Sometimes, if web.config file is not opening on VS editor, ASP Configuration browser page won't appear, so make sure that web.config is open in the VS editor and then try to access the Configuration.
I was having the same issue with a brand new ASP.NET project in Visual Studio 2012.
When trying to open Project --> ASP.NET Configuration from Visual Studio, it was saying: An error was encountered. Please return to the previous page and try again.
The path to my application was: E:\\_Dev\C#\Site
I changed the Path to: E:\\_Dev\Web\Site and guess what? It works.
So even the # from C# was causing an issue. This thing is very picky on special characters...

Resources