xaml - XmlnsDefinitionAttribute combined with x:Name causes compilation error with code generation -


I have and continue with using the XmlnsDefinition attribute in the Silverlight 4 assembly.

Here is the case of trial: [/ P> XmlnsDefinition ("vase: foo", "SilverlightApplication1.SomeNamespace")]

I MainPage.xaml Edit .cs and looks like this:

  Namespace SilverlightApplication1 {Public partial class home page: UserControl {public manpage ()} {InitializeComponent (); }}} Namespace SilverlightApplication1.SomeNamespace {Public Class SomeControl: ContentControl {}}  

Now I have the following in MainPage.xaml:

  & lt; UserControl X: Class = "Silverlight Application 1. Menopause" xmlns = "http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns: x = "http://schemas.microsoft.com/winfx/ 2006 / xaml "Xmlns: foo =" vase: foo "& gt; & Lt; Grid & gt; & Lt; Foo: SomeControl & gt; & Lt; TextBlock Text = "Hello World" /> & Lt; / Foo: SomeControl & gt; & Lt; / Grid & gt; & Lt; / UserControl & gt;  

The problem is compiled and running fine when I add the X attribute name to the SomeControl tag.

It does not compile:

  & lt; Foo: SomeControl x: name = "bar" & gt; & Lt; TextBlock Text = "Hello World" /> & Lt; / Foo: SomeControl & gt;  

By looking at the .g.i.cs file that is generated, the control is declared

  as some control panel internal;  

The file does not have either a statement or full name type to use. I have also tried to do WPF and the results are similar. Can anyone tell me, if anything, then I am doing wrong?

I have only one problem depending on my search, it seems that it is currently not supported is.


Comments

Popular posts from this blog

paypal - How to know the URL referrer in PHP? -

oauth - Facebook OAuth2 Logout does not remove fb_ cookie -

wpf - Line breaks and indenting for the XAML of a saved FlowDocument? -