locked
Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled RRS feed

  • Question

  •  

    Hi,

    1.   I am developing a web application in Visual Studio 2008.My application runs fine without debugging .

    But when I run with debugging ,I see that a Script Documents folder gets created in Solution Explorer and

    I can see many anonymous code files being created .

    One of the anonymous code files had the following text in it:

    function anonymous() {ValidatorOnChange(event);  } 

    The next anonymous code file had

    function anonymous() {if (!ValidatedTextBoxOnKeyPress(event)) { event.cancelBubble = true; if (event.stopPropagation) event.stopPropagation(); return false; } 

    }

     

    There are more files with this message in it .These are repeated again and again.

    when I closed the browser I got the following message in the debug output window.

    The stack trace is too long.But it has message mentioned below:

    Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled  for many dll files IN GAC.

    2.Secondly ,I get another  error message too i.e

    A first chance exception of type 'System.Threading.ThreadAbortException' occurred in mscorlib.dll  An exception of type 'System.Threading.ThreadAbortException' occurred in mscorlib.dll but was not handled in user code

    I did some analysis about this.I am using Response.Redirect statement in my code,so I added false as the second parameter along with the url.

    After that,when i debugged I did not get the exception error message for mscorlib.dll.

    But this message still appears :Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.

    I am more concerned about these messages ..Please guide me .I am not sure what is going wrong. 

    Thanks,
    cp


    cp_25
    Tuesday, November 18, 2008 2:50 PM

Answers

  • I'm not sure what exactly seems to be your concern. By default 'Just my code' option is enabled and with this options ON, VS will skip loading symbols for optimized dll-s. You can disable 'Just My Code' by unchecking this option in Options->Debugging->General. From what I understand your second issue is also something you probably shouldn't worry, since every Response.Redirect in ASP.NET causes ThreadAbordException.
    In general, debug output window displays the history of some of the things happened to your application during its lifecycle  including first-chance exceptions, module/symbol load information. You can also tweak the sources of your message by right-clicking on the debug output window and choosing the sources.

    Alex Bulankou, Microsoft Corporation. This posting is provided "AS IS".
    • Proposed as answer by Alex Bulankou Tuesday, November 18, 2008 3:56 PM
    • Marked as answer by liurong luo Wednesday, November 19, 2008 1:00 PM
    Tuesday, November 18, 2008 3:56 PM
  • 1. Based  on your initial question, I would suggest to keep 'Just my code' on and just ignore 'skipped loading symbols' messages, unless you wanted to set breakpoints etc. in code that belongs to the modules you're getting these messages for.
    2. I can confirm that according to msdn, ThreadAbort exception is expected after call to Response.Redirect. See here: http://support.microsoft.com/kb/817266 You can read more about ThreadAbort exception here: http://msdn.microsoft.com/en-us/library/system.threading.threadabortexception(VS.71).aspx 
    3. Anonymous code files are created so you can set breakpoints and debug your javascript code. If you don't intend to debug script code, you can check "Disable script debugging" in Internet Options->Advanced->Browsing in IE.
    Alex Bulankou, Microsoft Corporation. This posting is provided "AS IS".
    • Marked as answer by liurong luo Wednesday, November 19, 2008 1:00 PM
    Tuesday, November 18, 2008 5:04 PM

All replies

  • I'm not sure what exactly seems to be your concern. By default 'Just my code' option is enabled and with this options ON, VS will skip loading symbols for optimized dll-s. You can disable 'Just My Code' by unchecking this option in Options->Debugging->General. From what I understand your second issue is also something you probably shouldn't worry, since every Response.Redirect in ASP.NET causes ThreadAbordException.
    In general, debug output window displays the history of some of the things happened to your application during its lifecycle  including first-chance exceptions, module/symbol load information. You can also tweak the sources of your message by right-clicking on the debug output window and choosing the sources.

    Alex Bulankou, Microsoft Corporation. This posting is provided "AS IS".
    • Proposed as answer by Alex Bulankou Tuesday, November 18, 2008 3:56 PM
    • Marked as answer by liurong luo Wednesday, November 19, 2008 1:00 PM
    Tuesday, November 18, 2008 3:56 PM
  • Hi,
      Thanks for the fast response.

    1.So do you mean I should uncheck "Just My Code " option in Tools-Options-Debugging  ?... (OR)
    I could just just proceed my development work by ignoring  "Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled  " message.

    2.Can I confirm that there is not a problem in the .NET environment because of this error message?

    3.Could you please let me know why anonymous code files are created ?Is there a way to prevent those from happening?

    Thanks,
    cp
    cp_25
    Tuesday, November 18, 2008 4:09 PM
  • 1. Based  on your initial question, I would suggest to keep 'Just my code' on and just ignore 'skipped loading symbols' messages, unless you wanted to set breakpoints etc. in code that belongs to the modules you're getting these messages for.
    2. I can confirm that according to msdn, ThreadAbort exception is expected after call to Response.Redirect. See here: http://support.microsoft.com/kb/817266 You can read more about ThreadAbort exception here: http://msdn.microsoft.com/en-us/library/system.threading.threadabortexception(VS.71).aspx 
    3. Anonymous code files are created so you can set breakpoints and debug your javascript code. If you don't intend to debug script code, you can check "Disable script debugging" in Internet Options->Advanced->Browsing in IE.
    Alex Bulankou, Microsoft Corporation. This posting is provided "AS IS".
    • Marked as answer by liurong luo Wednesday, November 19, 2008 1:00 PM
    Tuesday, November 18, 2008 5:04 PM
  • Hi ,

    Thanks a lot .I have got an answer for my first and third question.I am able to understand your explanation.I appreciate for your quick response.

    My second question,."Can I confirm that there is not a problem in the .NET environment because of this error message?"

    what I meant was Can I confirm that there is no problem in my .NET environment/set up  in my development machine due to "Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled  "  error messages?


    Thanks,
    pcs
    cp_25
    Tuesday, November 18, 2008 5:31 PM