Skip to main content
  1. Tags/

Dotnet

Hooray (x 2) for MSDN library Community content

·2 mins

There are several steps to creating a custom web service to be hosted in SharePoint. The MSDN library{.} has a walkthrough on creating a custom web service{.}. After having followed this walkthrough thoroughly, I though my web service was good to go. Unfortunately all I saw was an error: “Could not load type ‘ThisAndThat’ from assembly ‘SoAndSo’”. Just as I was about to search for an answer somewhere online, I remembered that the MSDN library features the Community content for little over a year now{.} (hooray!).

Finally getting some coding done

·1 min

The last weeks have been filled with holidays and introductional days at my new employer{.}. Because of that, I haven’t had the time to realy dive into Visual Studio 2008, although I have played around with it since the RTM version was available. Since this week I’ve been writing some serious code in VS2008 for my new personal site (more about this later!). I can only agree with what Pieter de Bruin said in his post about the new line of developer tools and additions: “If you are building .NET 2.0 applications, you really should take a look at all of the above”.

“Some of the properties associated with the solution could not be read”

·1 min

Next to the message in the subject, one of the symptoms we encountered is that although the solution contains some test projects the ‘Create private accessor’ menu has disappeared. Also, selecting ‘Create unit tests…’ produces an error. And when editing a testrun config and selecting the ‘Code coverage’ option, the settings dialog simply closes, without any message.

Project template doesn’t understand AssemblyName tag?

·2 mins

At my current project we made a project template for Visual Studio for our testers. We added all the references, folders and files a tester needs to add a new system tests project. One of the testers (!) extended our XML generator, which generated XML testcases based on data entered in Excel, to now generate a complete C# test class. Making (system) tests which are automatically run during the nightly build now really is just as simple as entering data in Excel.

Nerd alert?

·1 min

I have lots of games for my Xbox 360 I still need to / want to finish, like The Orange Box and Bioshock. And despite this, I’ve been working ’non-stop’ behind my laptop for the last two evenings to prepare it for Visual Studio 2008, and to download and install it. It’s almost time… 😉

This is NOT a test.

·2 mins

Test Driven Development is hot, just like unit testing your software and any other kinds of (automated) testing. And as we all know: sometimes stuff that’s hot is misinterpreted, explained wrong or just simply used in a really bad way. Unfortunately, testing is no exception to this rule…

Build problem – Solved

·2 mins

Yesterday, I posted about a problem with MSBuild building our solution. We solved it, so I wanted to let you in on the secret solution.

We use the Enterprise Library V1.2 in some of our projects. And because some of the projects are being re-used from other internal projects, not all the references in thos projects were checked for versions. As it turned out, another project had a reference to an enterprise library assembly with a runtime version of .NET 2.0. And allthough this project compiled succesfully, local and on the build server, it broke the build of one of the other projects. This project (the one with the wrong reference) didn’t need the EntLib reference, so it ‘disappeared’ because of optimization. But reference resolving had resolved it, and pointed to EntLib 3.0. Later in the build the project which failed did need the EntLib file, and used the allready resolved assembly location.

MSBuild – Compilation error

·2 mins

Our current project uses the possibilities of MSBuild to have a daily build on a TFS server. This has been working up until yesterday somewhere around noon. Nobody knows what exactly happened, but it stopped working after our successful build of 11:42 am.

MSBUILD : warning : Specified cast is not valid

·1 min

At my current project we use Team Foundation Server together with the possibility to have a daily build through MSBuild. Over the weekend, the build failed. Because our ‘build master’ called in sick this morning, I took it upon me to fix the build. But compiling the sources was no problem, because that finished without any errors. And there were no failing (unit)tests. Even better: there were no tests which had run at all! There were ’no test results to display’. The only thing I found in the build log (which is pretty big in a 70+ project solution!) that could indicate a problem was a warning from MSBuild:

Unit Test Adapter threw an exception

·1 min

“Unit Test Adapter threw exception: System.Reflection.ReflectionTypeLoadException: Unable to load one or more of the requested types. Retrieve the LoaderExceptions property for more information..”

This error popped up at one of the testers of our project this morning. The unittests he selected worked fine on my machine, but all failed on his with the above message. After searching a bit we found that the only thing which was different between my testrunconfig and his was that he enabled code coverage for the assembly these unittests were pounding away at. As it turns out, this error appears when code coveraging (is that even a word?) a signed assembly without re-signing it.