Unable to start debugger on Older version of Visual Studio (2003) Under Windows 7 - asp.net

For this project I needed to install and run VS 2003 on Windows 7 using IIS 6.0 with Framework 1.1 on my sever because there was old VS2003 C# code on a remote server that needed updating and did not have VS 2003 installed only the DLL, PDB, aspx, and aspx.cs files. After porting the code over and making the needed changes on my local server, I discovered that while I could browse the page, I could not run the page with debugger and got this error: "... Unable to start debugging on the web server. There is no managed code running in the process. In order to attach to a process with the .NET debugger, managed code must be running in the process before attaching." I then started the application without Debugger and selected the w3wp.exe process for CLR in order to attach the process but I noticed that the process session was set to 0 and I still got that error again.
The following is done in IIS6 :
Application created.
DefaultAppPool (.NET framework 1.1 Integrated)(ApplicationPoolIdentity) is used
Browsing the web page works OK.
Authentication has Integrated Windows and ASP.NET Impersonation enabled.
I have runned aspnet_regiis from all the .net version in order
Set debug="true" in the web.config.
Thanks much for your help

Resolution:
Right click the ASP.Net project > Properties
select Configuration Properties > Debugging
Enable the below mentioned entries in 'Debuggers' frame.
ASP.Net Debugging
Unmanaged code debugging.

I had the same problem.
I fixed it.
Delete the virtual directory in IIS
Create the new virtual directory with different name other than the old one and configure the new virtual directory name in your visual studio solution.

Related

Visual Studio 2017 throws error on debugging an ASP.NET MVC application

I am setting up my new workstation (Windows 10 Pro) with my ASP.NET projects with Visual Studio 2017. I have enabled local IIS and the project throws a timeout error while trying to debug the project.
It is not failing 100% of the time though, mostly fails but when it runs it is taking longer than expected to give the startup page. The error thrown is
Unable to start debugging on the web server. The operation has timed out
I did notice that the IIS worker process (w3wp.exe) was only executed in the completed console output. So it looks like the IIS worker process is not always being executed.
Any help would be appreciated!
Thank you!
The project runs successfully on an old workstation (Windows 10 Edu) with Visual Studio 2017. App pool settings has been compared between both and it seems same. IIS reset is tried as well. Visual studio has been repaired and IIS local has been restarted as well (unchecking and enabling followed by restarting the machine). Default app pool is used and its been recycled as well. Nothing worked!
Possibly the Visual Studio project version does not match the ASP.NET configured application pool. Update the ASP.NET version in the application pool and restart it.
Make sure you have the correct version of ASP.NET installed on IIS. A version mismatch between ASP.NET in IIS and the Visual Studio project can cause this issue. May need to set the framework version in web.config. To install ASP.NET on IIS, use the Web Platform Installer (WebPI).
If the issue is not related to IIS configuration, try the following steps:
Restart Visual Studio with administrator privileges and try again.
For example, using the Web to deploy some ASP.NET debugging scenarios that require elevated Visual Studio privileges.
If you are running multiple instances of Visual Studio, reopen your project in one instance of Visual Studio (with administrator privileges) and try again.
If using a HOSTS file with a local address, try using the loopback address instead of the computer's IP address.
If not using a local address, make sure the HOSTS file contains the same project URL as in the project properties, Properties > Web > Server or Properties > Debug, depending on the project type.
Reference link:
Visual Studio "Unable to start debugging on the web server. The web server did not respond in a timely manner.".

Attach to Process is not working in Visual studio 2008 in Windows 7

Today i had a wired issues with Visual Studio 2008 SP1 running in Windows 7 32bit Machine with IIS7 installed.
I am developing a web application. I have set up the default website in local host in IIS (IIS 7.0) to run the website and it is working fine when i press F5,the process runs and show break point locations. But when I try to debug the site by selecting attach to process from debug menu and select the browser process (IE8 or Mozilla), nothing happens and the process doesn't hit the break point. What am I doing wrong?
Thanks in advance for the help.
You should attach to the IIS worker process (w3wp.exe).
Check you have build the process in debug mode and pdb files are deployed with dll's.
Go to Project Properties > Build Tab > Click Advanced button >Now Set Debug Info to "Full".
In the Web.config file, change the line that reads
<compilation debug="false"/> to <compilation debug="true"/>.
How to: Attach to a Running Process, VS Express Edition does not allow attaching a process for debugging

ASP.Net Application deployment on Windows Server 2003

I'm trying to deploy an ASP.Net application I developed to a Windows Server 2003 System but I get a error message when running the Site.
The first thing is that I get a Null Reference exception when I want to access my custom configuration section. So I figured that maybe the System.Configuration Assembly might not be installed. However I removed the reference and included the database directly into code to see if it works without.
But now I'm getting another error that a third party server control is not recognized.
Error Message: Server label
"trirand:JQGrid" unknown.
The same application runs just fine on my XP machine with IIS 6 installed so I wonder if I'm missing some installation. This is the first ASP.Net Application on that machine as before there were only ASP tools. I think that the .Net Framework 3.5 SP1 is installed but I'm not sure. Another question is if the ASP.Net is integrated into the .Net Framework of if I need a different install package.
Update:
I experienced a weird behaviour: I added the obviously wrong element <asdf> to the web.config file. On my development machine that gave me the expected error, but on the server nothing happened at all. So it seems like it some does not recognize my web.config file.
You need to check if the windows server system is loaded with the software your application required.
The folder v3.5 should be there in the following location.
C:\WINDOWS\Microsoft.NET\Framework\v3.5
Also you need to check if asp.net is installed on the system, if you are not sure then do install it, installing it if it is already there have no side effects.
To install asp.net type the following commands in DOS prompt.
cd C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727
// then
aspnet_regiis.exe -i
Then also, confirm in IIS that correct version of asp.net is selected for your website.
To check; go to your website properties in IIS
then select ASP.NET tab then check ASP.NET version it should be 2.0.50727 for websites below .net version 4.0
Good Luck!

Visual Studio can't create web site in IIS

After installing service pack 1 for Visual Studio 2010 cannot create web site in IIS. Here is error message:
---------------------------
Microsoft Visual Studio
---------------------------
Configuring Web http://localhost/MyWebSite for ASP.NET 3.5 failed.
You must manuallyconfigure this site for ASP.NET 3.5 in order for
the site to run correctly. Visual Studio cannot detect whether this
virtual root has been configured for use with ASP.NET 2.0. The likely
cause is that you do not have sufficient priviledges to access the
IIS metabase. You may need to manually configure this site for
ASP.NET 2.0 in order for your site to run correctly.
---------------------------
OK Help
---------------------------
Does anybody know how to fix it ? Thanks!
P.S. I'm using windows7 x64.
Have you tried run Visual Studio with "Run As Administrator" from right click?
This happened to me when I deleted the default application pool.
Thanks to a Microsoft Connect report, I was able to solve this by choosing a new default application pool under the "Web Site Defaults" properties of the Sites node in the IIS 7 Manager tree.
Try changing the .Net version your Application Pool is using.
Open IIS Manager from Administrative Tools.
Select Application Pools on the left.
On the right, double click 'DefaultAppPool' (or whichever you may have created)
Under .Net Framework Version select v3.5.
Click OK and restart IIS.
I don't know if you have to restart IIS or not, but it won't hurt.
I found the answer here:
Visual Studio 2013. You do not have sufficient privilege to access IIS web sites on your machine
IIS stores a config file on your personal drive. At my company our shared drive was down for maintenance and I was getting this error. Once the drive came back online VS.NET started working again.

Debug .NET app with IIS7 and Delphi.NET - Use aspnet_regiis.exe to configure the local IIS web server

I have been trying to set up local debugging for my ASP.NET app in Delphi and am getting the error above. I have used the aspnet_regiis.exe tool with the following:
Aspnet_regiis.exe -s W3SVC/1/ROOT/DevTest
but this hasn't helped. It added it to IIS as an application but I am still getting the error:
The project cannot be debugged because virtual directory "DevTes" is not configured with ASP.NET version 2.0 or 3.0 Use aspnet_regiis.exe to configure the local IIS web server.
I am not really sure where to go from here so need some help please:
Machine specs: Windows 7 64bit, IIS7, Using RAD Studio 2007.
EDIT: For more info, I have been able to start the website in Firefox and have been able to attach to process now, although the debugging is lacking a little, i.e I can't see values of sessions ect ...
Try using the Web Platform Installer to configure IIS for ASP.NET development. http://www.microsoft.com/web/Downloads/platform.aspx

Resources