Error loading DefaultTemplate.xaml in designer
I can't load my projects' DefaultTemplate.xaml file开发者_如何学运维 in the designer. (using VS2010 premium, recently reinstalled) When loading the DefaultTemplate.xaml from the build templates in TFS, I get an error saying that the activity cannot be loaded. There are errors loading the namespaces. Somehow it cannot find the assemblies needed for TFS. In the errors list I get about 50 complaints about these namespaces.
I've poked around in it, but never commited any changes. I've tried restoring the original version, but that didn't work. I've tried replacing the template with the DefaultTemplate.xaml from another project, but I got the same error. I'm at a loss here. How can I fix my VS2010 or template so I can edit it again using the designer? I can open other projects' DefaultTemplate.xaml files in the designer without any problems.
I suspect that it has to do with some setting in VS2010 or my project somehow not having the right references, but I can't figure out what's wrong or how to solve it.
Hope this or this will address your issue.
Edit:
If above doesn't work try below, you may get more descriptive error by using this. This works for windows applications on VS2008. I've never tried this with VS2010. You can debug your devenv.exe instance by another devenv.exe. Below are the steps. Give it a go...
1) Start a second instance of visual studio
2) go the the Tools menu, "Attach to process", select the 'devenv.exe' process, and click the 'attach' button.
3) In the Debug/Exceptions menu Turn on exception catching when first thrown (in the Debug->Exceptions menu).
4) Open the designer with the debugger attached
5) The second visual studion will break on your error.
精彩评论