I'm trying to come up with some code that I can use to add INFO level tracing to my DAL and BL code. So far, I'm able to obtain plenty of metadata about the functions, but not the actual parameter values:
StringBuilder sb =
new StringBuilder();
sb.Append(System.Reflection.MethodBase.GetCurrentMethod());
ParameterInfo [] ParameterInfos = System.Reflection.MethodBase.GetCurrentMethod().GetParameters();
foreach (ParameterInfo ParameterInfo in ParameterInfos)
sb.Append(" ").Append(ParameterInfo.Name).Append(" {").Append(ParameterInfo).Append("}");
TraceLog.Info(sb.ToString());
this will output the metadata about the parameters, but not the actual values. For example, it will show me that the value is an Int32, but not that the value is 3.
I know that this is doable, but I can't seem to pick the right combination of words, punctuation, and secret masonic dances required to get Google to return a clue.
Any clues?
Edit: oh, and what the heck is the 'code' tag on C9 again?
Thread Closed
This thread is kinda stale and has been closed but if you'd like to continue the conversation, please create a new thread in our Forums,
or Contact Us and let us know.