Template10: unable to use designer

Created on 2 May 2016  路  18Comments  路  Source: Windows-XAML/Template10

Hi, I'm just trying to use template 10 to start an app, but I have problems using the designer.
I read about problems migrating from previous versions, so I unsistalled the latest version of the vsix and reinstalled 1.17 version, and created a new app using the hamburger template.
When I try to open the DetailPage, the MainPage, the SettingsPage, the Shell in the designer I Can't see anything for problems loading

Could not load file or assembly 'Microsoft.Xaml.Interactivity, Version=1.1.0.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies. A strongly-named assembly is required. (Exception from HRESULT: 0x80131044)

I'm using a vs 2015 update 2.
Am I missing something? the app compiles, run but I cannot see the pages in the designer

All 18 comments

Known issue, will compile and run

I know it's working, I would like how can I use the designer otherwise I have to write xaml directly proceding by mistake

@lucamorelli Template10 has strongly named reference to Behaviors SDK 1.1.0. You have two potential solutions to get things going for designer.

  1. Disable user code running for designer.
  2. Avoid using (or temporarily comment out) lines in XAML that use Actions or Behaviors from T10.

More information here.

@JerryNixon Can we please get rid of the strongly named reference? To my knowledge, Behaviors team has already done that.

hmm ... I didn't use XAML a lot in the last times, so start a uwp app without designer slow me down a bit. How can I disable user code?

This comment in the link I previously posted explains that. In addition to it you will also be able to an option to do so when the designer crashes and reports exception.

BTW, guys, a bit more detail is necessary.
When they say "disable user code running in the designer", that means do two things:
1) Click on the line in designer that says "click here to disable running project code ... and reload designer". it isn't referred to as user code
BUT WAIT... your designer may still be running, and visual studio will continue to use it with the old setting IF you don't ....
2) Open Task manager, and select any instances of Visual Studio XAML designer, and press "End Task"

The complete info: https://msdn.microsoft.com/en-us/library/mt622752.aspx

-this may help
-e

Yeah, the T10 strong-named assembly is the problem. T10 re-enabled strong-naming, at the same time as Behaviors disabled it, which is the source of this problem. See #860 for more details.

@JerryNixon is aware of this issue, I would hope he is working on a fix.

thanks. now it's working

That's all right. Sorry I can't be of more help with the strong-naming problem. Like I said, @JerryNixon is aware of this problem. He definitely considers it a major (and irritating) issue, and I hope he's working on a fix.

There are a few other issues with design time due to the lack of windows if you are using any of the dispatcher calls (or anything that calls any of the dispatcher calls, or window wrapper, etc). IsBusy for example will blow up. Its fairly easy to attach the debugger to the designer to try and track down what breaks it. I am not sure how much interest there is in trying to designer safe some of these classes, but I had started looking at what is required to do so.

@mitchcapper I doubt that debugging will help much. You could find the cause of designer's crash. But there's hardly anything we can do to fix it - other than making changes to the project code.
As a side note, I have tried and followed a bunch of instructions trying to attach a debugger to the designer. I can never do that. Is there a place where there are easy to follow and working instructions so that I can find out what I am doing wrong?

@akshay2000, he's not intending to debug the designer. He is talking about root causing, and resolving, several unrelated issues in Template 10 regarding classes that are not designer safe, which can cause designer crashes. This issue is not related to any class, it is as a result of T10 using strong-naming, and Behaviors 1.1.0 (which T10 makes use of) lacking it.

Correct the T10 stong typing is an issue if you use certain behaviors (and it will crash the pageheader) but the rest of the app should be usable except for various other issues with the designer. As for debugging the designer its not too bad, but you want to compile for x86, do a full compile then attach to XDesProc.exe and it should work no other steps needed. Just then load a view that crashes and it can help with the why.

I think T10 should be made completely designer safe. It's a good idea to fix these issues, because design mode data is extremely useful, and it's a pain in the backside not being able to use it.

Do we have an ETA for a working version of the template or a fix that doesn't involve removing VS functionality?

Thanks!
Bjarne

No idea. AFAIK, the easiest fix is to disable strong-naming in T10. I'm not sure if @JerryNixon is willing to do that, there are some definite benefits. The fix (no matter how annoying) is the best option at present, as this issue shows no signs of going away soon.

I'm sure @JerryNixon will do what is best for T10. I'm hoping for quick turn-around. The blue wavy lines aren't pretty. Jokes aside, it is impossible to learn how to use the framework, when I dont know if the errors are mine or a side-effect of strong-naming....

You guys are a great community. I am disabling sn today.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

Weasy666 picture Weasy666  路  8Comments

marcinmarkiewicz picture marcinmarkiewicz  路  9Comments

JerryNixon picture JerryNixon  路  9Comments

Joebeazelman picture Joebeazelman  路  5Comments

mjmeans picture mjmeans  路  10Comments