I love WPF

"jamais sans son interface"

I love WPF

"jamais sans son interface"

Day: 13 septembre 2017

Set component in default namespace

If you want to use your own compenent you muste speicfy an xmlns:xxxx= » » in xaml and use like this <xxx:myComponent ….. if you want to set your compenent on global or specific namespace 1- create a project 2– place component in this project 3– add this line in assemblyinfo.cs of this project [assembly: XmlnsDefinition(« http://schemas.microsoft.com/winfx/2006/xaml/presentation », « UltimateCorp.Components »)] […]

ColumnDefinition visibility

To have visible Binding on ColumnDefinition (idem a RowDefinition) use this class public class ColumnDefinitionExtended : ColumnDefinition { // Variables public static DependencyProperty VisibleProperty; // Properties public Boolean Visible { get { return (Boolean)GetValue(VisibleProperty); } set { SetValue(VisibleProperty, value); } } // Constructors static ColumnDefinitionExtended() { VisibleProperty = DependencyProperty.Register(« Visible », typeof(Boolean), typeof(ColumnDefinitionExtended), new PropertyMetadata(true, new PropertyChangedCallback(OnVisibleChanged))); […]

Retour en haut