This project has moved. For the latest updates, please go here.

TraceFormatter.cs dependent on System.Windows.Forms

Jul 22, 2011 at 12:19 PM

Hi,

In Diagnostics\TraceFormatter.cs, method EnsureApplicationName(), if you replace:

applicationName = Path.GetFileNameWithoutExtension(Application.ExecutablePath);

with:

string apppath = new Uri(Assembly.GetEntryAssembly().CodeBase).LocalPath;
applicationName = Path.GetFileNameWithoutExtension(apppath);

you can remove the potentially problematic dependency on System.Windows.Forms.

I created an issue for this.

Thanks for the nice package and the relevant examples!

Danny