Visual Studio always upgrade my solution

I’m upgrading a Visual Studio 2010 solution to a Visual Studio 2012 one. It’s part of a migration of a solution from SharePoint 2010 to 2013 (and there are good details about this here). Annoyingly, though, every time I open the project it says that it has ben upgraded and shows an Upgrade Report. Nothing appears to be modified, but still, it’s shown.

Google didn’t show a lot of help on this, but in the end I decided to simply open the .csproj file and look for some sort of flag about being upgraded. I found the element:

<FileUpgradeFlags>0</FileUpgradeFlags>

so I tried deleting the ‘0’ and reloading the project – and it didn’t show an Upgrade Report. Hurrah. Not sure why I needed to so this, though.

Advertisements
Visual Studio always upgrade my solution

TFS: Solution Explorer missing file status icons

I’ve just had a bit of a problem with Solution Explorer in Visual Studio not showing the ‘checkout status’ icons from TFS – you know, the red tick, the padlock, etc.. These things:

I couldn’t figure out what was causing this, but found the solution on MSDN forums:

In VS 2010, while you have the solution open in Solution Explorer, select File-> Source Control-> Change Source Control, could you click on Bind for each project/solution? Binding provides version control functionality. This includes various version control icons that indicate status in Solution Explorer.

This advice was correct – I went to the binding dialog, and the solution and projects weren’t bound. I added the bindings back – and presto. I’m not sure, however, how the project became unbound…

 

TFS: Solution Explorer missing file status icons

Sandbox Development – Reference the User Code DLL

Remarkably, I’ve only just started doing my first Sandboxed development in SharePoint 2010. (Most of our customers own their own servers, and want functionality you can’t easily build in the Sandbox alone).

Anyway, I knew that the API you could use in the sandbox was smaller than the full API, and I wanted my solution to warn me (e.g. fail to compile) if I tried to use something that wasn’t available in the sandbox. I found two approaches… Continue reading “Sandbox Development – Reference the User Code DLL”

Sandbox Development – Reference the User Code DLL

Attaching Visual Studio 2010 to Outlook 2010 plugin for Debugging

I was trying to attach a debugger to an Outlook plugin I was working on. It was originally written for Outlook 2003, but has been progressively upgraded to 2010. However, I couldn’t breakpoint my code, or rather, the breakpoints weren’t being hit.

Found the answer on Stack Overflow:

So it turns out that Outlook doesn’t load the CLR on startup (it must be loaded shortly thereafter when it becomes necessary), which apparently confuses the VS debugger and causes it to only debug native code. To force it to load the CLR immediately, create an OUTLOOK.EXE.config file in the same folder with:

<configuration> <startup> <supportedRuntime version="v2.0.50727"/> </startup></configuration>

which is from this blog post. Then, even when VS starts attached, it will debug CLR code

Attaching Visual Studio 2010 to Outlook 2010 plugin for Debugging

Editing a XAML build process

So, we’ve been working on putting our SharePoint solutions through a proper build process in Team Foundation Server 2010 (TFS), and I hit a bit of a snag.

I had been given a build definition that had a build process – a Workflow Foundation workflow – that I wanted to alter. The problem was that while I had the XAML file for that workflow, and the DLL that defined some custom code activities that the process used, I didn’t have a full Visual Studio project for it. No problem, I thought, I’ll just open the XAML up in Visual Studio and edit it.

Wrong.

Continue reading “Editing a XAML build process”

Editing a XAML build process

WSPBuilder 2010 and TFS2010

With SharePoint 2007, WSPBuilder became our standard packaging tool for SharePoint solutions. It was simple, powerful, and a damn site easier than trying to write your own manifest.

Well, SharePoint 2010 and Visual Studio 2010 followed later, and Microsoft introduced much better tooling of their own. However, we’ve still got a lot of code being packaged by WSPBuilder, and we didn’t want to have to refactor all those projects just to package them for 2010.

Fortunately, Carsten Keutmann wrote a 2010 version (still in ‘BETA’, but it works fine). It offers many of the same extensions to Visual Studio as the previous version did.

However, I recently had to automate (in Team Foundation Server 2010) the build of one of our WSPBuilder based solutions, and that’s where things got more interesting… Continue reading “WSPBuilder 2010 and TFS2010”

WSPBuilder 2010 and TFS2010