Fix exception that occurs when designer is loaded in VS2013