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
LVL 1
Bharath A.KAsked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

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

function checkif()
{
debugger;
//your code
}
Bharath A.KAuthor Commented:
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
Prakash SamariyaIT ProfessionalCommented:
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!!
Big Business Goals? Which KPIs Will Help You

The most successful MSPs rely on metrics – known as key performance indicators (KPIs) – for making informed decisions that help their businesses thrive, rather than just survive. This eBook provides an overview of the most important KPIs used by top MSPs.

MlandaTCommented:
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
Bharath A.KAuthor Commented:
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.

Regards,
Bharath AK
Untitled.png
MlandaTCommented:
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
Prakash SamariyaIT ProfessionalCommented:
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!
Bharath A.KAuthor Commented:
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
MlandaTCommented:
I believe that the author should assign points to the experts that helps to reach the conclusion: "Thanks for your reply.  I am debugging from IIS express. ie. why I am not able to see w3wp.exe". The experts help provide clarity that when using IIS Express, there would be no w3wp.exe

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
Bharath A.KAuthor Commented:
Hi MlandaT,

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

With Many Thanks,

Bharath AK
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
ASP.NET

From novice to tech pro — start learning today.