Link to home
Start Free TrialLog in
Avatar of coder
coderFlag for Australia

asked on

how to debug aspx file, how to debug javascript from visual studio?

Hi Experts,

I am not able to see w3wp.exe.  I had run vs 2013 as administrator. I had checked show process for all users while debugging I am not able to find w3wp.exe(for Attach to debug process),  Then also I am not able to see the w3wp.exe.    
I have to debug the java script file.  Please help

Thanks in Advance.

With Regards,
Bharath AK
Avatar of Prakash Samariya
Prakash Samariya
Flag of India image

If you want to debug the javascript, simply use "debugger;" statement in whatever function you want to debug!

function checkif()
//your code
Avatar of coder


Hi Prakash,

thanks for your reply, Could you please tell me how to load w3wp.exe by attaching to debug process and debug aspx file.  I had tried show all process for all users and I am running visual studio 2013 in administrator mode.  But I am not able to see w3wp.exe to attach to debugger to debug aspx file.
Please through some light.

Thanks in Advance,

With Regards,

Bharath AK
Thanks for reply, please follow steps

A. Enable javascript debugging fron Internet explorer
1. IE->Tools menu->Internet Options->Advanced tab
2. (Browsing category) uncheck/clear "Disable script debugging check box"
3. Click OK and Close IE take effect
B. Attach your browser to Process for Debug
1. In the Attach to Process dialog box, find Internet Explorer, iexplore.exe, and select it.
2. Click "Select to" select the code type to debug.
3. In the Select Code Type dialog box, under Debug these code types, select Script.
Close all dialog box and Attach to Process dialog box.

This will enable you to debug javascript into Visual Studio!!
how to load w3wp.exe by attaching to debug process
w3wp.exe is not always running. You need to first browse to your application in the browser (so that the application pool starts up). Also make sure that when you are on the Attach to Process window, you check the "Show processes from all users" checkbox. Alternatively, just press F5 in Visual Studio with your web project as the default Start-up Project
Avatar of coder


Hi MLandaT,

I had the done the same steps.  I had loaded visual studio -> Run as administrator.  while debugging I had done show process from all users.  After loading the default.aspx, I am not able to see w3wp.exe.
Please help am I missing any steps, I am not able to see the w3wp.exe.  Please help.  please see untitled.png for reference.

Thanks in Advance.

Bharath AK
Is your project set to use IIS Express or the Local IIS? Check under the Web tab in your project properties. If using IIS Express you might not see a w3w.exe

What happens if you just press F5? What url do you see in the browser? If you see http://localhost:99999/ then you are probably using IIS Express
IIS worker process(w3w.exe) comes in picture when you host your application in IIS.  If you didn't hosted your application, then it wouldn't show that! From VS when you run the web application, by default it runs in IIS Express, (as MLandaT suggested) please check if your application is running inside IISExpress or IIS.

If your application runs under IIS (not IISExpress), then steps provided by me in previous post (ID: 40986749) would enable you to debug the same!
Avatar of coder


I've requested that this question be closed as follows:

Accepted answer: 0 points for AK_Bharath's comment #a40986690

for the following reason:

Hi Experts,

Thanks for your reply.  I am debugging from IIS express. ie. why I am not able to see w3wp.exe
Avatar of Mlanda T
Mlanda T
Flag of South Africa image

Link to home
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of coder


Hi MlandaT,

      Thanks for your reply.  I accept this as a solution.

With Many Thanks,

Bharath AK