No mapping data was returned from the server after installing ASP.NET and Web Tools 2012.2 Update - asp.net

Went to http://weblogs.asp.net/scottgu/archive/2013/02/18/announcing-release-of-asp-net-and-web-tools-2012-2-update.aspx, downloaded and successfully installed the update but now when I try to view my site in page inspector it tells me "No mapping data was returned from the server". Created a new MVC4 app, and in that project page inspector works fine.
I made sure Web Essentials 2012 extension was updated to the latest version prio to installing the 2012.2 update like the blog says. Also this page wasn't much of any help: http://msdn.microsoft.com/en-us/library/jj204395.aspx:
Error
No mapping data was returned from the server
Description
Page Inspector can’t map between the browser and source code.
Cause
Not determined.
Fix
No specific recommendations.
Any idea what could be wrong and what else I should try?
Edit:
This is superweird. I did absolutely nothing and now all of the sudden it works again!
Unless closing and opening Visual Studio and the project a couple of times counts.
This is how it looks now - notice the difference in the first and last bullet:
Edit2: Used IISExpress in both projects. "No mapping data was returned from the server". Sounds like it could be an issue with IISExpress not liking the new stuff that where installed?
Edit3: This piece of code breaks page inspector:
<map id="surfer" name="surfer">
<area shape="poly" coords="0,23,30,13,40,3,64,5,69,19,86,23,98,30,99,51,72,63,68,83,41,83,38,67,1,65" alt="&%##?!">
</map>
Never thought that it could actually break an entire tool so didn't bother to test. Here's where I got the tip: http://social.msdn.microsoft.com/Forums/sv/visualstudiogeneral/thread/470ece78-86c3-4fab-b38c-cb969d515d43
Seems like a bug in page inspector/razor engine or in both.

Caused by a bug in page inspector/razor engine. Will get fixed soon. See Anands comment in question.

Related

ASP.NET site not updating after changes

So, I have a pretty basic ASP.NET site that was built and published via ftp through VS. Original publication went fine, as did the first few updates. But now I've made page changes (css as well as in the aspx files) and they don't seem to get pushed to the server. I believe that my code behind (C#) files are being updated since there are a few visual elements I call in the code. When I look at the ASPX files, they have old dates and the code is the prior version. VS says the publishing succeeded, and the host (GoDaddy) says there's no caching or quota issues on their side. If I upload a new dummy page it goes through... so it looks like updated pages are the issue.
What am I missing?
If it's styles have you tried doing a hard-refresh on your browser? If everything is saying the files are updated then maybe you have a locally cached version.

IIS express suddenly not displaying web page

Perhaps someone can help me figure out what's going on.
I'm running VS 2013 and working on a Web Forms application (not an MVC app). I'm using the templates that came down, including all the cool FriendlyUrls functionality. I've been working on this website for several weeks without any problem.
Today, for no apparent reason, one of my pages stopped working. When I attempted to view it, I got an error message that the server was not configured to list directories. My web page does not attempt to list the contents of any directory. It just has some images and some relatively simple Javascript (which does not attempt to enumerate anything).
The error message suggested I run the following command in the IIS Express directory:
appcmd set config /section:system.webServer/directoryBrowse /enabled:true
Just for the sake of experimenting, I ran that command. Now when I attempt to view the page, I get something that looks like this (the page is named Menus.aspx)
localhost - /Menus/
[To Parent Directory]
Clicking on "To Parent Directory" takes me to the home page, as one might expect.
I created a new page, Menus2.aspx, and copied all of the code from Menus.aspx into Menus2.aspx, and Menus2 runs fine. In addition, when I upload the site to Azure, Menus works correctly (as does Menus2). So I think my code is innocent of any wrongdoing.
I then deleted Menus.aspx and renamed Menus2.aspx to Menus.aspx, and I'm back to the same problem.
I was working in a git branch, and reverted back to master to see if at least my original configuration would work, but now even in master I can't get the page to come up.
So it looks like the problem is that something got jacked up in my local configuration, but I can't for the life of me figure out what it is. I have exited VS and rebooted the machine in hopes that the problem will disappear as mysteriously as it started, but no luck.
Every other page in the site (6 so far) works fine. It's just this one, with this name.
So my options at this point are to simply not have a page named Menus.aspx in my project because the name has somehow become cursed, or do all of my testing by uploading to the server and seeing how it works up there, which is a pain and should not be necessary.
Can someone suggest how and where I should start looking for what happened here? This isn't the problem I expected to be working on today.
Thanks in advance.
-Rob

Getting .asmx file in browser is fine, getting .asmx?WSDL returns an empty page

I created a webservice in a .dll and put this in the windows\assembly directory.
I followed all steps shown in the following URL and stopped at the paragraph "Creating a Windows Application to Consume the Web Service", because my consumer is a Lotus Domino agent:
http://msdn.microsoft.com/en-us/library/ms464040.aspx
There are two installations, where it worked just fine, now I did this on a third computer and when I browse the URL to the asmx file in a browser (IE9, Firefox 12 & Chrome 19) I get the normal answer from the IIS 7. But when I click on the link for the service description
(.../DominoImporter.asmx?WSDL) all I get is an empty page! IE9 shows the default 404 page and in Chrome I have a white page with no source. Firefox shows an error message, that describes the empty page with a header of type XML.
This doesn't work:
hostname/_vti_bin/DominoImporter.asmx?WSDL
This works:
hostname/_vti_bin/DominoImporterwsdl.aspx
I searched half this day for differences between the three installations / computers but found nothing!
All forum help found by Google also discussed other problems than mine.
I think there has to be someone, who already has experienced the same problem & can give me advice!?
Ok, now I found a solution, I deinstalled Visual Studio 2010 and after this I deinstalled Sharepoint Foundation 2010. Then I reinstalled Sharepoint Foundation 2010 and installed Visual Studio 2012.
Then when I load the WSDL again, the resulting web page in the browser isn't empty anymore!
Wrote this, maybe someone else might need this solution in the future.
Turned out, that my Sharepoint installation was corrupt. Couldn't clarify this before out of time pressure with a higher prioritized project.
comment following line in web.config of webservices project.
<add name="ContentTypeHttpModule" type="Porthos.Signup.Extras.ContentTypeHttpModule, ContentTypeHttpModule"/>
Right click your service and view in browser.
Click on Service description and it will show you wsdl.
Additionally it will also resolve updating web reference error.

Visual Studio | ASP.NET Configuration error

I have a problem as I have struggled with for a week.
Now I give up! I really can not figure out how to solve it. Every time I open the ASP.NET Configuration in VS10, then comes the first with this error:
**An error was encountered. Please return to the previous page and try again. **
If I then press:
How do I Use this Tool
so this comes up:
**Tool Has Timed Out
As a security measure, the Web Site Administration Tool times out after a period of inactivity. Changes to machine.config or web.config may also result in the tool needing to be restarted. To continue configuring your web site, restart the tool. **
Some who can answer me on what's happening here?
"Special characters in the path may be the problem, according to the posts." as Posted above by Dave Swersky
THIS worked perfectly for me! I had a special character ("#") in my folder path I removed this and removed spaces for good measure!
I was getting the error "Tool has timed out" among other errors when accessing the WSAT(Web site administration tool) from the ASP.NET configuration menu item.
I saw a post somewhere else that said the problems was solved when the default browser was changed to Internet Explorer. I have been using Firefox and have the exact same problem. When I changed the default browser to IE, the configuration page came up with no problem. But it won't work twice in a row without going in and setting the default browser back to IE each time. When I go back in to Program Access and Defaults, "Use by current browser" is selected. I have to reselect IE, and then it will work one time.
Judging by the Connect site, this error has been reported and is not well understood:
http://connect.microsoft.com/VisualStudio/feedback/details/118567/an-error-was-encountered-please-return-to-the-previous-page-and-try-again
Special characters in the path may be the problem, according to the posts.
This is what worked for me.
I'm using Visual Studio 2010 trying to create the membership role. I was trying to use the ASP.NET Configuration in Visual Studio.
Set the 'Default Browser' to Internet Explore.
To do this:
Right click on one of the .aspx pages you have under "Solution Explorer".
Select "Browse With..."
Select Internet Explore and Click on Set as Default.
Close the box.
Go back and click on "ASP.NET Configuration"
This will automatically open Internet Explorer.
Problem Solved :D
I guess what I was doing wrong was using Firefox as the default browser with Visual Studio. I'm guessing Visual Studio works good together with Internet Explorer since Momma and Daddy made them together (awww how cute)
The issue might be related to an application path that has spaces. After googling I managed to bypass the issue by appending the application path to the url manually ie.
http://localhost:{your_port_here}/asp.netwebadminfiles/default.aspx?**applicationPhysicalPath={path_to_your_application}&applicationUrl=/**
As a firefox user, I closed firefox then executed the "ASP.NET Configuration" option in VS2010. It automatically opens firefox (default browser) and now I am seeing WAT page contents.

Why would an aspx file return 404 ("The page cannot be found")

Why when I access an aspx (e.g., http://www.example.com/foo.aspx - not the real site) through IE6 would I get a 404 Error (i.e., "The page cannot be found") in IIS6
I've got scripts enabled for the website and I've tried with executables enabled as well.
Here is the full error:
The page cannot be found
The page you are looking for might have been removed, had its name changed, or
is temporarily unavailable.
------------------------------------------------------------------------------
Please try the following:
Make sure that the Web site address displayed in the address bar of your
browser is spelled and formatted correctly.
If you reached this page by clicking a link, contact the Web site
administrator to alert them that the link is incorrectly formatted.
Click the Back button to try another link.
HTTP Error 404 - File or directory not found.
Internet Information Services (IIS)
------------------------------------------------------------------------------
Technical Information (for support personnel)
Go to Microsoft Product Support Services and perform a title search for the
words HTTP and 404.
Open IIS Help, which is accessible in IIS Manager (inetmgr), and search for
topics titled Web Site Setup, Common Administrative Tasks, and About Custom
Error Messages.
I can get to Default.htm in the same directory, so I know the path is right. I've opened it up to everyone (temporarily) so I know the permissions are right.
It could be a lot of things. I had this issue today because .NET had not been re-initialized after installing IIS (aspnet_regiis -i -enable or equivalent).
Check that the anonymous user under which the site runs has read access to the file foo.aspx.
IIS6 and later uses a 404 response, thereby not letting an attacker know whether such a file even exists.
I just happened to find another culprit for this issue. My foo.aspx page referenced a particular master page that had a <%# Register %> directive to a user control that did not exist. Removing the reference to the non-existent user control caused my foo.aspx to load instead of 404.
I found a solution here.
The real catch was using this:
Response.TrySkipIisCustomErrors = true;
The site is pointing to a different directory where the page is not.
It could be permissions, however I would think you would get an access error instead.
I'm assuming you are running IIS.
Check that www.example.com is going to the site that you think it is.
If you are hosting multiple sites on the same IP using host headers you may want to double check the name you are using is going to the site you think it is.
Ray and Joe probably have it. In order to serve any file type, IIS has to have a mapping for it. Aspx files require that they be mapped to the AspNet ISAPI dll, which the .Net installation normally takes care of. If you install IIS after .Net (and I'm sure there are other situations), you have to initiate this yourself by running aspnet_regiis.
ALTERNATE SOLUTION (same error perhaps different cause).
I had installed Visual Studio 2008 Pro without SQL Express it, and it caused this same error. Reinstallation of VS2008 with sql express included seemed to have corrected the problem, or perhaps the install took other actions. I did try to register ASP.net numerous times prior but no luck however it is definitely the most probable cause Just posting my experience for those pulling their hair as I was..
Thanks
If you register the .NET 4 version of IIS, you may find it's grabbed the registration of the aspx extension. If ASP.NET v4 is prohibited then 404 will be returned
I had this issue where some customers were reporting the 404.0 and some didn't have the problem at all(same page). I was able to navigate to any of the pages with no problems from my machine. Some customers would refresh and it would go away. I am using .Net 4.5.2 and IIS 7.5.
Looking at the IIS log file I would see:
sc-status sc-substatus sc-win32-status
404 0 2
sc-status.sc-substatus: 404.0 - Not Found
sc-win32-status: 2 - ERROR_FILE_NOT_FOUND
https://msdn.microsoft.com/en-us/library/windows/desktop/ms681382(v=vs.85).aspx
https://en.wikipedia.org/wiki/HTTP_404
I found the problem was I had deployed a new version of the website in which the old version of the website had RouteConfig.cs/FriendlyUrlSetting setup by creating a project using the web forms template. The new version was created using an empty template. So obvious to me now.. no URL routing. Customers had a cache issue with certain pages on their machine(no .aspx extension) and having them clear browser data ultimately fixed the problem.
I got this issue when I tried using a different drive to host my apps. I ended up moving them to the wwwroot folder because it was working there and I did not have to time figure out why it is not working on the E:\ drive.
I had bin\roslyn compiler missing. Adding that all worked fine.
Check for double quote errors. I started getting a 404 on a single page because I accidentally had this:
<asp:TemplateField HeaderText="ImageURL"">
instead of this:
<asp:TemplateField HeaderText="ImageURL">
For an aspx page, error 404 can be quite misleading! I have seen all the answers and they presuppose assuming various issues with the file, page, path, etc. but the simplest issues is the fact that if there is an error in your asp page (i.e bad format, improper usage of control, etc. asp will think the page does not exist and will post a 404 when in all actuality, it is easy to ascertain if there is a bad format by simply clicking on design mode. If the page does not render no need to do anything else but look at what is causing the render error, fix and viola'! Your page shows since it was never missing or can't be found, but it simple did not know how to display! Too often people go looking for the wrong solutions and waste so much time! Hope this helps somone. :-)

Resources