Your wish is granted.
The good folks at Microsoft predicted your need eons ago.
From within your ASPX code;
Trace.Write ( whatever you want to be logged );
Place this anywhere in your code, as often as you require.
In your Web.config, look for the following section;
<trace
enabled="true"
requestLimit="100"
pageOutput="false"
traceMode="SortByTime"
localOnly="false"
/>
Make sure to set enabled to "true"; I also like to set localOnly to false
and to increase the requestLimit.
Run your page, do your testing, and then CTRL+N to open a new browser
window. Change the Url to;
http://yoursite/trace.axd
or
http://yoursite/yourvirtualdir/trace.axd
if you're using virtual directories
You'll be surprised at what you find.
/// M
"Aaron" <ku*****@yahoo.com> wrote in message
news:11*********************@f14g2000cwb.googlegro ups.com...
this is what I want to do.
i have an input box and a submit button. the input gets processed by my
program and it returns the results. depending on the input, not all the
functions in my program are called, some might be called multiple
times, the order of functions called might be different each time. I
would like to log all this, what function actually got called...
this is my plan
create a global string named TRACE
in each function add its name to trace
string processInput1(string input)
{
//process input
...
TRACE = TRACE + "processInput1";
return input
}
but this is method is clumsy. is there a builtin function in dotNet?
please show me a good example.
Thanks in Advance
Aaron