.NET Reflector change local variable name,even with pdb file

mono4hackmono4hack Posts: 7
edited October 22, 2016 7:47AM in .NET Reflector Previous Versions
I'm using .NET Reflector V9 Visual Studio Extension.
I know that local variable name saved in PDB file not in Source code,

Issue(s)
1) the local variable names have been changed to (numxx, strxx, listxx,) even I have the original PDB file.

Question
1) How I use PDB file to get original variable name in generated source code.

Comments

  • Jessica RJessica R Posts: 1,319 Rose Gold 4
    Hi and thanks for your post!

    Can you kindly make sure that under Tools>Options>Disassembler, the "Show PDB Symbols" option is ticked?

    If it's not, that's likely why the local variable names are being renamed to things like numxx, strxx, listxx.

    I hope that helps!

    Jessica Ramos | Product Support Engineer | Redgate Software

    Have you visited our Help Center?


  • Thanks Jessica for your reply, but where do I can found Tools>Options>Disassembler (Show PDB Symbols) ? do you mean in visual studio or what?
    N.T I use .NET Reflector V9 Visual Studio Extension.
    sorry for my poor language.
  • Jessica RJessica R Posts: 1,319 Rose Gold 4
    Ah I thought you were using the .NET Reflector desktop application, apologies for the confusion! The Tools>Options>Disassembler (Show PDB Symbols) option is only available for the desktop application.

    Just to clarify though--is the pdb file you have the one that was generated with .NET Reflector? If so, I'm afraid that .NET Reflector can't create a pdb file with the original local variable names as these are stored only in the original pdb file. Instead it will create its own generic names like the ones you are seeing.

    Please let me know though if I'm still misunderstanding!

    Jessica Ramos | Product Support Engineer | Redgate Software

    Have you visited our Help Center?


  • Thanks Jessica, I got the Idea and it work with .NET Reflector desktop application.
    but can I use .NET Reflector desktop application -> to generate original source code
    side by side with
    .NET Reflector V9 Visual Studio Extension -> to use debugging functionality.
    So that use all .NET reflector features , It will be very good point.
Sign In or Register to comment.