Steve Michelotti

A .NET Developer's Toolbox

  Home  |   Contact  |   Syndication    |   Login
  199 Posts | 0 Stories | 1106 Comments | 51 Trackbacks

News

View Steve Michelotti's profile on LinkedIn

profile for Steve Michelotti at Stack Overflow, Q&A for professional and enthusiast programmers




Google My Blog

What I'm Reading:

Shelfari: Book reviews on your book blog

Tag Cloud


Archives

Post Categories

Code

Publications

.NET 2.0

The .NET 2.0 Configuration API is a huge step up from the previous versions of the framework rendering many other previous configuration framework (Enterprise Library Configuration block, etc.) virtually obsolete. However, one thing that can trip people up is when they try to assign to a configuration property at run-time you can get a ConfigurationErrorsException - The configuration is read only even when a setter is defined on their property: [ConfigurationProperty(item... DefaultValue = ......

I recently had to debug a problem for my current client which was exceptionally weird and I was able to utilize WinDbg to help get to the bottom of the problem relatively quickly. Basically the application in question is an asp.net application that takes a custom object and puts in in an MSMQ message (which currently uses the default binary serializer). The class in question is marked with the Serializable attribute, has a couple of primitive members (e.g., ints, strings) and a couple of NameValueCollections. ......

This is a great post that anyone who works with WinDbg should check out:

http://geekswithblogs.net/.netonmymind/archive/2006/03/14/72262.aspx

Bookmark it - it will come in handy anytime you're debugging with WinDbg.

There is a known bug when trying to build 64-bit MSI files. That is, the wrong InstallUtilLib.dll is embedded in the MSI. A workaround to that problem is to use Orca to manually manipulate the MSI file in embed the correct version - the workaround is documented here. However, what if you want to automate this process on your build server? Orca is a windows appication requiring user input. To automate this from the command line, you can leverage a few lines of VBScript code that essentially duplicates ......

This past summer I had an article published in Visual Studio magazine in which I outlined a Validation framework that I created to declaratively validate business objects.  Simon Cropp has taken the initiative to put the source code up on CodePlex as an open source community project.  It can be found here:

http://www.codeplex.com/ValidationFramework


This error often rears its ugly head when compiling an ASP.NET 2.0 Web Deployment Project. At first glance, it is extremely difficult to troubleshoot because there is not much information along with the error. In order to troubleshoot this, you need to use a higher level of verbosity. If you're using MSBuild from the command line you can use the /verbosity switch like this (and then look at Output window for build): C:\projects>msbuild YourSolutionFile.sln /t:Rebuild /p:Configuration=Release /verbosity:detailed ......

I just had an article published in the June issue of Visual Studio magazine. The article essentially presents a flexible framework for validating business objects utilizing attributes. http://www.visualstudiomaga... This is my first time in “print”! The direct link to my article is: http://visualstudiomagazine... A couple of people had trouble downloading the code from the VSM site. Alternatively, it can be downloaded here: http://www.4shared.com/file... ......

I just had an article published in the June issue of Visual Studio magazine. http://www.visualstudiomaga... This is my first time in “print”! The direct link to my article is: http://visualstudiomagazine... A couple of people had trouble downloading the code from the VSM site so I'm happy to provide directly. The article essentially presents a flexible framework for validating business objects utilizing attributes ......

An interesting issue came up today that, although it now looks simple, did not have an immediately obvious solution. Specifically, what if you want to set properties of individual columns of a GridView at run-time (via C# code) rather than at design time in the aspx code. For example, let's say you want to set the DataFormatString property of a BoundField column. In short, it is a 2-part solution. First, you must positionally extract your column out of the GridView's Columns property while casting ......

Often when a new language features come out (in this case anonymous method) we often see syntax examples like this: delegate void SomeDelegate();public void InvokeMethod(){ SomeDelegate del = delegate() { MessageBox.Show("Hello"); }; del(); } and we say, great but when is code like THAT ever going to be useful to me? In that trivial example, of course that's not very useful. But when you consider the power anonymous methods gives you both to pass in parameters and also make use of local objects then ......

Full .NET 2.0 Archive