Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Leon 101 posts 489 karma points
    Mar 30, 2015 @ 17:31
    Leon
    0

    razor debugging break points not working no symbols have been loaded

    Hello.

    I'm not getting debugging to work in Visual Studio 2013 community edition. I'm trying to debug a razor view template. I get this error: "the breakpoint will not currently be hit. No symbols have been loaded for this document". I've tried to clean the solution and I've rebooted my machine.

    Any ideas?

    Leon

  • Leon 101 posts 489 karma points
    Mar 30, 2015 @ 17:39
    Leon
    100

    Oh, I got it fixed. Break points are working, but visual studio stopping on an error still doesn't work (not so bad for me). Not sure why this works, but here are my two code snippets:

    Not Working:

    var newsItems = site.Children().Where(x => x.Name == "Muse News").FirstOrDefault();
    if(newsItems.Children()) ...
    

    Changed to this and then debugging break point started working again:

    var newsItems = site.Children().Where(x => x.Name == "Muse News").FirstOrDefault();
    if(newsItems != null)
    

    Looks like the debugger won't kick in if there are certain obvious errors?

    Leon

Please Sign in or register to post replies

Write your reply to:

Draft