2

I am using Windows 8 and Visual Studio 2012 to run an ASP.NET web application locally. Problem is I can't figure out how to attach the debugger. I tried debug>start debugging but it gives me the following error...

Error Message

I added a breakpoint in my code and tried starting/hitting site, but no dice. I also checked my project and ensured ASP.NET debugging was checked and confirmed the proper config in my web.xml.

Any ideas?

Update:

Ok I can attach to the process using the following.... enter image description here

But it still says my symbols have not been generated...

And when I try to connect to iisexpress instead I see...

enter image description here

8
  • Your project file might be corrupted. But you should still be able to manually attach by going Tools > Attach to Process > w3wp.exe
    – Dai
    Jun 12, 2013 at 23:24
  • no process matches that name
    – Jackie
    Jun 12, 2013 at 23:33
  • 1
    my mistake, IIS Express doesn't use w3wp.exe, instead attach to iisexpress.exe, see here: weblogs.asp.net/nmarun/archive/2011/05/05/…
    – Dai
    Jun 12, 2013 at 23:38
  • I think it doesn't attach to that process. I will try again and let you know.
    – Jackie
    Jun 12, 2013 at 23:54
  • Added pic of what happens when I try to attach, do I need to install debug symbols on IIS or something?
    – Jackie
    Jun 13, 2013 at 0:00

3 Answers 3

4

You need to attach the debugger to iisexpress.exe. Although this worked for me it did throw up an error at first so my assumption is that it can just be ignored. I am marking this as the solution for now, however, if someone comes up with a better answer I will switch.

0

It looks like you are trying to start a library project and not an asp.net project.

Do you have more than one project in your solution? Try right clicking your project file and clicking 'set as start up project' and debugging it again.

If you only have the one project in your solution, or you are sure the right project is set as the start up project, then you probably created the wrong project type for it. Create an asp.net project and move your files over into that.

1
  • I disagree because why would the asp.net debug be checked if it wasn't ASP. At least give me a place to look. Also, if it isn't an ASP.net shouldn't you be able to change the type instead of copying all the files from one project to another?
    – Jackie
    Jun 12, 2013 at 23:57
0

Make sure your project is a asp.net project. If it is, right click on the project and select "set as startup project", then try running it.

1
  • I would assume it is set up as an ASP.NET project as the properties have ASP.NET debugging checked but it does not give me the option to set as startup project. That is greyed out.
    – Jackie
    Jun 12, 2013 at 23:35

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.