See the question and my original answer on StackOverflow

I don't think you can get (parameters) values from the .NET stack from the program itself, only methods, properties, classes, ie: anything that comes from .NET metadata.

If you want values, here are a some solutions:

  • instrument your code before compilation, adding lines of code to capture parameters values
  • instrument your code after compilation, with things like PostSharp for example (disclaimer: I'm not affiliated in any way)
  • write a .NET profiler, but this must be an external program. There a existing tools that do this already, like this one: CLR profiler. Version 4 of the CLR profiler (available here) comes with the source.