Question

I have some custom controls that I would like to make more 'user friendly' in Cider (VS wpf designer). I have red all the documentation in MSDN and some sites that I found through google , but I did not find answers to some simple questions :

  1. How to set default values for the items that are created from a collection editor (like columns in datagrid, not drag-drop from toolbox)
  2. How to generate XAML (like the datagrid dose when you click generate columns)

Please let me know if you know of any doc that goes into details such as those mentioned above.

Also if you know/have any custom controls with visible source code that have designer support (like Xceed or DevExpress) please share a link.

Was it helpful?

Solution

This an excellent and rare book that goes deep into custom controls development:

WPF Control Development Unleashed: Building Advanced User Experiences

OTHER TIPS

Recommended books:

1- www.amazon.com/Pro-WPF-2012-Presentation-Professionals
2- any book about Design Pattern like www.amazon.com/3-0-Design-Patterns-Judith-Bishop
3- MVVM to add a column to data grid you don't need to generate xaml, there is a column collection you can add one by code behind

dataGrid1.Columns.Add(new DataGridTextColumn{ Header = "column1"});

read the first book well and you will be good

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top