2011-07-15 50 views
2

如何告訴xaml serilization忽略屬性。 IE相當於xml序列化的XmlAttributes.XmlIgnore屬性。XmlAttributes.XmlIgnore等效於XAML

Class MyObject 

    'Is there an equivalent of this for xaml? 
    <XmlIgnoreAttribute()> Public Property DontSerializeMe as String 

End Class 
+0

的可能重複[C#屬性XmlIgnore和的XamlWriter類 - XmlIgnore不工作(http://stackoverflow.com/questions/4575555/c-attribute-xmlignore-and -xamlwriter級-xmlignore - 不工作) –

回答

2

是:

[DesignerSerializationVisibility(DesignerSerializationVisibility.Hidden)]