If you are new to use the Code Contracts Library from Microsoft one exception you may run into is this
Description: Must use the rewriter when using Contract.Requires<TException>
What this error is telling you is that you must turn on the runtime checking for the project which hosts the code.
One thing to pay attention to is that you MUST turn this on not for the project which calls the code w/ contracts, but rather the project that actually has the contracts call in it.
BTW, in order to get the Code Contracts pane in the project options you must down load the latest version of the CC library from MS Research.
Hope this helps the next person w/ this error.
Till next time,
06-30-2010 6:36 AM