Updating DBML via drag/drop in Visual Studio 2012 not working

I don’t usually work with Linq 2 SQL DBML’s anymore, but today I had to work on a project that still used them. I needed to update some tables, so I removed them as I always do, and then tried to drag/drop them from the Server Explorer.

But not today…. today Visual Studio decided that the Server Explorer would not allow me to even begin dragging a data connections table, let alone dropping it on the DBML.

After some creative googling I found out that the problem was with the file called dsref80.dll. This file is located in the following folder on an x64 machine: “C:Program Files (x86)Common FilesMicrosoft SharedVisual Database Tools”. On my machine it had the following version:

Thats right, it says Visual Studio 2013 Preview (something I had already removed due to some other problems I had a couple of weeks ago). So the uninstall of Visual Studio 2013 Preview had left this file lying around. Causing Visual Studio 2012 to panic and not load it, which in turn breaks the drag/drop action of a Table object from Server Explorer to my DBML surface.

You could probably fix this issue by manually removing this file and then running a Visual Studio 2012 repair. But this is a somewhat time-consuming endeavour. So I opted for the fast route which goes as follows:

– Find a machine with Visual Studio 2012 installed that never had the Visual Studio 2013 Preview installed.
– Copy the dsref80.dll from that machine to your own machine, overwriting the 2013 one.
– I didn’t even have to restart VS or reload the DBML, drag/drop worked again instantly.

The version of the correct file showed as follows:

0 thoughts on “Updating DBML via drag/drop in Visual Studio 2012 not working

  1. Willem

    Thanks. After testing VS 2013, I returned to using VS 2012 and experienced the same issue.
    Solved!

    Reply
  2. Chami

    Thanks, I found in other forum files replacement do the trick. But this is my only laptop. so i delete it and repaired it.

    Reply

Leave a Reply to Marcel Cancel reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.