hi guys,
Is there any tool for C# that shows the running fragments of source code
at runtime or at least facilitate the navigation into source code I mean reading the source code.

Recommended Answers

All 5 Replies

I'm not sure what you are asking. Are you wanting a stack trace that allows you to navigate into the points (method calls) of execution?

If you ship your application with source code and debug symbols you can get the callstack from Environment.StackTrace which will contain the file name and line number. With that information you could open it up in your favorite text editor.

You can read the source of .NET assemblies using .NET Reflector. You can also use ildasm provided with the SDK but that's only if you can read IL fairly well.

yes but reading the source with the reflector won't give you accurate line numbers without having debug symbols since comments are ommited and the source isn't exactly decompiled 100% as it was.

yes but reading the source with the reflector won't give you accurate line numbers without having debug symbols since comments are ommited and the source isn't exactly decompiled 100% as it was.

This is true. But then again I would think that there wouldn't be any third-party tool that would give you 100% accurate source feedback. In that case I guess you'd be right; it should be done through the compiler.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.