Blog?

I'm sure you have something better to do

Visual Studio XAML designer annoyances

 

UPDATE: MSFT has released a patch for the XAML designer in Visual Studio 2008 SP1. This patch appears to fix some edge cases with the designer that cause it to crash VS. You can get the patch here: http://code.msdn.microsoft.com/KB958017

I pretty much abandoned the integrated XAML designer in VS long ago. It is painfully slow to load and even after waiting several minutes for it load it usually just shows the brilliant "We're sorry... our designer blows" screen. Recently a co-worker was having some problems with XAML files crashing Visual Studio. He had just installed VS 2008 SP1 and .NET 3.5 SP1. No idea what the issue was but I suggested that he try switching his XAML editor to open XAML pages in full XAML view. I realized that maybe other people don't know how to do this since the option is buried pretty deep.

 

So a quick to post to show how to do this.

In the VS IDE click Tool | Options

ToolsOptions

 

Then expand the tree for Text Editor

TextEditor

 

Scroll down and you should see a XAML section. Expand the XAML tree

 

XamlTree

 

Then click on the Miscellaneous item. Now you will see a check box that says "Always open documents in full XAML view"

 

FullXamlView

Click OK and you are all set. Now when you open XAML files in VS they will open in full markup view. This prevents the designer from loading. This should speed up the time it takes to open XAML files. And in some cases it looks like it prevents the IDE from crashing. Interesting to note, after making this change my coworker was able to switch to design view and reload the designer and this time it did not crash Visual Studio. hmmm? Race condition maybe?

Posted: 10-20-2008 5:00 PM by Brad Cunningham | with 3 comment(s)
Filed under:

Comments

mike said:

Yep, the XAML designer pretty much blows. I was quick to check that box as soon as they added it.

# October 22, 2008 9:18 AM

Niki said:

Thanks for this!!!  It's been driving me nuts and I just hadn't looked for that yet.

# December 18, 2008 1:55 PM

ScottC said:

I tracked down my XAML crashing IDE issue to PowerCommands - this site offers a fix that worked for me.

code.msdn.microsoft.com/.../View.aspx

# June 22, 2009 11:45 AM
Leave a Comment

(required) 

(required) 

(optional)

(required)