Jeroen Derde's Blog

My Software Engineering Universe

Visio 2010 XSD

clock June 6, 2011 23:28 by author Jeroen Derde

About a week ago Microsoft published the XML Schema Definition (XSD) files for the Microsoft Visio 2010 XML Drawing (.vdx) format. This schema is also known as DatadiagramML.
This should make it alot easier to use the visio file to generate code based in the visio file.

The DatadiagramML Schema for Visio 2010 consists of three .XSD files:

  • visio.xsd is the core schema used by Visio 2003 and later
  • visio12.xsd is the set of extensions used by Visio 2007 and later
  • visio14.xsd is the set of extensions used by Visio 2010

More information about the schema is available in the Visio 2010 XML Schema Reference on MSDN.

RegEx Searching in Visual Studio

clock June 19, 2010 00:44 by author Jeroen Derde

This article lists the aliasses you can use in visual studio when searching with a regular expression.,ide).aspx

For example  if you want to find all guids in your solution

  • CTRL-SHFT-F (find in files)
  • Entire Solution
  • check the Use Regular Expressions box
  • type in the find box :h^8-:h^4-:h^4-:h^4-:h^12
  • go


Add Get PublicKeyToken to Visual Studio

clock June 2, 2010 21:18 by author Jeroen Derde

Article about how to add a "Get PublicKeyToken" menu item in Visual Studio

Basic steps:

  • Tools --> External tools..
  • Title: Get PublicKeyToken
  • Command: C:\Program Files\Microsoft SDKs\Windows\v6.0A\Bin\SN.exe
  • Arguments: -T $(TargetPath)
  • Check Options: Use Output window

Make sure you build your project before using this new tool.
I love this, and think it should be added on every developers machine.

UserControls in WSPBuilder Project

clock May 13, 2010 02:14 by author Jeroen Derde

WSPBuilder extensions for Visual Studio are great. If you use WSPBuilder to create webparts however, you might have run into the fact that by default Visual Studio does not allow you add Web User Controls to a WSPBuilder project.

At the project I'm currently working on, we use WSPBuilder and usercontrols for the visual part of the webparts we create. To make life a bit easier we altered the projectfile of our webparts project.

If you change:




Visual Studio wil think it is now a WebApplication, and will allow you to add usercontrols by using Add --> New Item on your WSPBuilder project.

SP2010 Site and Web Feature Id's

clock December 16, 2009 01:48 by author Jeroen Derde

Thanks to Jeffrey Tummers for retrieving the id's

  <!-- Content Type Syndication Hub -->
  <Feature ID="9a447926-5937-44cb-857a-d3829301c73b" />
  <!-- Document ID Service -->
  <Feature ID="b50e3104-6812-424f-a011-cc90e6327318" />
  <!-- Document Sets -->
  <Feature ID="3bae86a2-776d-499d-9db8-fa4cdc7884f8" />
  <!-- SharePoint Server Enterprise Site Collection features -->
  <Feature ID="8581a8a7-cf16-4770-ac54-260265ddb0b2" />
  <!-- SharePoint Server Standard Site Collection features -->
  <Feature ID="b21b090c-c796-4b0f-ac0f-7ef1659c20ae" />
  <!-- Workflows -->
  <Feature ID="0af5989a-3aea-4519-8ab0-85d91abe39ff" />
  <!-- Metadata Navigation and Filtering -->
  <Feature ID="7201d6a4-a5d3-49a1-8c19-19c4bac6e668" />
  <!--SharePoint Server Enterprise Site features-->
  <Feature ID="0806d127-06e6-447a-980e-2e90b03101b8" />
  <!--SharePoint Server Standard Site features-->
  <Feature ID="99fe402e-89a0-45aa-9163-85342e865dc8" />

Don't set your SharePoint trustlevel to full

clock November 10, 2009 00:29 by author Jeroen Derde

A really nice (and funny) article why you should not do this, by Tyler Holmes.

I came across this article because we had an assembly containing a feature reciever that would cause an error when executed.
Assemblies containing feature recievers should always go in the GAC (by design), but we where creating a custom policy.

So, I agree with Tyler that custum policies are still preferable, but when you have a dll that contains a feature reciever, you should just put it in the GAC.

.Net University

clock October 9, 2009 21:52 by author Jeroen Derde


Free download of Powerpoint slides, demos, video's and example code of around 40 .net courses.



LINQtoSQL cheatsheet

clock August 21, 2009 22:56 by author Jeroen Derde






DamienG, just posted a LINQ to SQL cheatsheet for C# and

Download it at:



clock August 18, 2009 19:45 by author Jeroen Derde







Phil Haack just posted about REST and ASP.NET MVC.
He explains why the WCF team at Microsoft has put together an SDK and samples for building REST services using ASP.NET MVC.

The post can be found at:

I'll be giving this SDK a go, and keep you updated on my findings.

You might also want to take a look at this article about building a WCF REST client:


WittyTwitter TwitterLib

clock July 14, 2009 23:34 by author Jeroen Derde


Found this .Net wrapper for the Twitter API called TwitterLib. It's part of WittyTwitter, but can also be used on it's own.

Code can be found here.
Nice if you are planning on building a twitter enabled app.





clock July 10, 2009 01:29 by author Jeroen Derde

Today I was experiencing a problem in the MVC application I am currently developing.

First some information:

Model: ContactDataModel
ContactDataModel implements interface IContactData. This is because the related typedview Step1 contains a partialView that inherits IContactData.
this way we can reuse the partial view simply by having each model, that needs to use the partialview, implement this interface.


Interface IContactData

public interface IContactData
    ContactData Contact { get; set; }


Object ContactData

public class ContactData
    public string Voornaam { get; set; }


View: Step1
This view inherits from ContactDataModel

<% Html.RenderPartial("ContactDataUserControl"); %>


Partial View: ContactDataUserControl
This view inherits from IContactData

<%@ Control Language="C#" Inherits="System.Web.Mvc.ViewUserControl<QNH.Interfaces.IContactData>" %>
<%= Html.ValidationSummary("Create was unsuccessful. Please correct the errors and try again.") %>
<% using (Html.BeginForm()) {%>
        <label for="Contact.Voornaam">
        <%= Html.TextBox("Contact.Voornaam")%>
        <%= Html.ValidationMessage("Contact.Voornaam", "*")%>
.........more fields....form closed


Controller: MyController

public ActionResult Step1( ContactDataModel contact )


The "POST" method "Step1" on MyController was recieving an empty ContactDataModel object. If I changed the the Step1 method to recieve the FormCollection instead of the Model object then my values would be present. After this I thought: what object is responsible for mapping the formvalues in my view to my model object. The answer is: the ComplexModelBinder.

The main thing to remember when using the ComplexModelBinder is the naming convention of your controls in the form. Because it uses reflection the ComplexModelBinder is expecting the Class Name + “.“ to be appended to the property name. If you are using the ComplexModelBinder and not prefixing the Class Name to the name of the Property, you will just get null values for your properties.

This means that in my partial view were I was using Contact.Voornaam I needed to use ContactData.Voornaam.This also means that I needed to change the name of the property in my interface to ContactData, because else it would not be recognised.

New Interface: IContactData:

public interface IContactData
    ContactData ContactData { get; set; }

New Partial View: ContactDataUserControl
This view inherits from IContactData

<%@ Control Language="C#" Inherits="System.Web.Mvc.ViewUserControl<QNH.Interfaces.IContactData>" %>
<%= Html.ValidationSummary("Create was unsuccessful. Please correct the errors and try again.") %>
<% using (Html.BeginForm()) {%>
        <label for="ContactData.Voornaam">
        <%= Html.TextBox("ContactData.Voornaam")%>
        <%= Html.ValidationMessage("ContactData.Voornaam", "*")%>
.........more fields...form closed


I really hope this helps out someone else. Happy Coding.


xVal - a validation framework for ASP.NET MVC

clock June 24, 2009 03:03 by author Jeroen Derde

Via Codeplex, and a bit later on Steve Sanderson’s blog I found some information on xVal.
xVal is, as the title of this post states) a validation framework for ASP.Net MVC.


A qoute from Steve's post that got me very exited to start using xVal.

"xVal lets you link up your choice of server-side validation mechanism with your choice of client-side validation library.
It guides you to fit them both into ASP.NET MVC conventions, so everything plays nicely with model binding and errors registered in ModelState."

What this means to me is that I can implement clientside validation via JQuery Validation( but if the client does not support JavaScript all validations will also be done serverside.
The validation is also only defined once (on the modal) which makes for much easier maintenance. This is quite a big deal because many of our customers require that the webapplications we build adhere to the accessability rules set by the Dutch government.(

Order a pile of pizza's because I'll be experimenting with xVal and ASP.Net MVC the next couple of days.

PS: if you don't know about DataAnnotaions yet, read this first:

Web Platform Installer 2.0 Beta

clock June 24, 2009 01:20 by author Jeroen Derde

Today I was creating a new Virtual PC to do some ASP.Net MVC programming. After duplicating my standard image I went to and was preparing myself to download a couple of installers. Then I saw a button in the top left corner that said: Install Now with the Microsoft Web platform installer.

Web Platform Installer is like a stack. It enables you to install everything you need to start web developing at once and then some more.

This made getting my development machine up and running much easier. It also introduced me to some tools I had never heard of before, which is a big plus aswell.








Month List


<<  January 2023  >>

View posts in large calendar

Sign in