CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 9 of 9
  1. #1
    Join Date
    Dec 2009
    Posts
    596

    Debugging Javascript with FireBug and Visual Studio

    Hello everyone,

    I just installed FireFox for the first time so I have version 14 and have the FireBug addon setup. FireBug 1.10. I still haven't been able to figure out how to set up FireBug/FireFox to get Visual Studio to stop on a breakpoint in a javascript function. Can someone please tell me exactly what it is that I need to do with this version of Firebug and or FireFox so that I can step through javascript code in Visual Studio 2010?

  2. #2
    Join Date
    May 2002
    Posts
    10,943

    Re: Debugging Javascript with FireBug and Visual Studio

    Do you have Visual Studio's default previewer set to Firefox and not IE?
    If the post was helpful...Rate it! Remember to use [code] or [php] tags.

  3. #3
    Join Date
    Dec 2009
    Posts
    596

    Re: Debugging Javascript with FireBug and Visual Studio

    Howdy,

    Yep I have Visual Studio setup to use FireFox by default. The projects in Visual Studio open in FireFox. If I could get this VS/FireFox environment to break on the breakpoint I'll be happy. It's still not happening.

  4. #4
    Join Date
    Oct 2006
    Location
    Sweden
    Posts
    3,654

    Re: Debugging Javascript with FireBug and Visual Studio

    Have you checked that Control Panel / Internet Properties / Advanced / Disable script debugging (others) isn't checked?
    Debugging is twice as hard as writing the code in the first place.
    Therefore, if you write the code as cleverly as possible, you are, by
    definition, not smart enough to debug it.
    - Brian W. Kernighan

    To enhance your chance's of getting an answer be sure to read
    http://www.codeguru.com/forum/announ...nouncementid=6
    and http://www.codeguru.com/forum/showthread.php?t=366302 before posting

    Refresh your memory on formatting tags here
    http://www.codeguru.com/forum/misc.php?do=bbcode

    Get your free MS compiler here
    https://visualstudio.microsoft.com/vs

  5. #5
    Join Date
    May 2002
    Posts
    10,943

    Re: Debugging Javascript with FireBug and Visual Studio

    That's for IE, not Firefox.
    If the post was helpful...Rate it! Remember to use [code] or [php] tags.

  6. #6
    Join Date
    Oct 2006
    Location
    Sweden
    Posts
    3,654

    Re: Debugging Javascript with FireBug and Visual Studio

    Ok but why is there one box for IE and one for others then?
    Debugging is twice as hard as writing the code in the first place.
    Therefore, if you write the code as cleverly as possible, you are, by
    definition, not smart enough to debug it.
    - Brian W. Kernighan

    To enhance your chance's of getting an answer be sure to read
    http://www.codeguru.com/forum/announ...nouncementid=6
    and http://www.codeguru.com/forum/showthread.php?t=366302 before posting

    Refresh your memory on formatting tags here
    http://www.codeguru.com/forum/misc.php?do=bbcode

    Get your free MS compiler here
    https://visualstudio.microsoft.com/vs

  7. #7
    Join Date
    Dec 2009
    Posts
    596

    Re: Debugging Javascript with FireBug and Visual Studio

    Yep, disable script debugging other(and internet explorer) are Not checked. I'm working on a project in which some test code that gets data from a web service won't work under Internet Explorer but works fine in FireFox, so that's why I'm doing the FireFox thing. Ordinarily I would be just fine working with IE.

  8. #8
    Join Date
    May 2002
    Posts
    10,943

    Re: Debugging Javascript with FireBug and Visual Studio

    Quote Originally Posted by S_M_A View Post
    Ok but why is there one box for IE and one for others then?
    "Other" is for Windows scripting host (wscript). It's still scripting, but not directly in Internet Explorer. For example: If you run a VBScript (*.vbs) from the desktop for renaming folders or something.

    Quote Originally Posted by viperbyte View Post
    Yep, disable script debugging other(and internet explorer) are Not checked. I'm working on a project in which some test code that gets data from a web service won't work under Internet Explorer but works fine in FireFox, so that's why I'm doing the FireFox thing. Ordinarily I would be just fine working with IE.
    If it's working fine in Firefox, then Firebug shouldn't throw any errors anyway. So, in this case, you want debugging turned on for Internet Explorer.
    If the post was helpful...Rate it! Remember to use [code] or [php] tags.

  9. #9
    Join Date
    Oct 2006
    Location
    Sweden
    Posts
    3,654

    Re: Debugging Javascript with FireBug and Visual Studio

    Quote Originally Posted by PeejAvery View Post
    "Other" is for Windows scripting host (wscript).
    well now everybody knows how often I do something in that area...
    Debugging is twice as hard as writing the code in the first place.
    Therefore, if you write the code as cleverly as possible, you are, by
    definition, not smart enough to debug it.
    - Brian W. Kernighan

    To enhance your chance's of getting an answer be sure to read
    http://www.codeguru.com/forum/announ...nouncementid=6
    and http://www.codeguru.com/forum/showthread.php?t=366302 before posting

    Refresh your memory on formatting tags here
    http://www.codeguru.com/forum/misc.php?do=bbcode

    Get your free MS compiler here
    https://visualstudio.microsoft.com/vs

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured