Posted on: 3/31/2011 8:41:13 PM | Views : 791

I'm using a log file to document info while getting and processing info from a form
1. if not post back, open the log file, build page, send form. 2. get submit back from form, possible post back if errors,  possible writes to log file, if no errors definitely writes to log file, and send confirm page. 3. postback from confirm page can either be going back to form or finalizing, and send acknowledge page, then done.
so I need to keep the logfile object between direct postbacks to the form, or posting back to orignal form page after gettting a postback from a confirm page.
this type of file setup works fine, it creates a single log file per day: lf = System.IO.File.AppendText(appsPath & "\" & dateStr & "training.log")   then successive writes are like this:  lf.WriteLine(msg) lf.Flush()
when the form submit comes back from the original send/submit, lf fr ...

Go to the complete details ...