I am watching a programming presentation from the Myspace tech team right now. They are going over their stats and was blown away by the numbers (as of April 2007):

Scott in: ASP.NET 2.0, Technology
I am watching a programming presentation from the Myspace tech team right now. They are going over their stats and was blown away by the numbers (as of April 2007):

Scott in: ASP.NET 2.0, C#, Enterprise Library, Exceptions, Programming
When Enterprise Library was called Microsoft Application Blocks, if you wanted to log an Exception, you would write (assuming “ex” is an Exception):
ExceptionManager.Publish(ex)
And if you wanted to log some extended properties you could do something like this:
NameValueCollection customerInfo = new NameValueCollection();
customerInfo.Add("name","scott");
customerInfo.Add("email","blah@blah.com");
ExceptionManager.Publish(ex,customerInfo);
Now that I am upgrading all legacy code to Enterprise Library 2006 for .NET 2.0, I couldn’t find a way to do this since the only way to log an error is:
ExceptionPolicy.HandleException(ex, "General Policy");
where “General Policy” is the name of the Exception Policy in the config file telling the Block what to do with the exception.