views:

382

answers:

0

I need to build a spreadsheet-like control in WPF with the following features:

  • Frozen columns
  • Frozen rows
  • Cell merge
  • Ability to have arbitrary user controls hosted in a cell with their own data binding targets

I do not need any calculation or formatting functionality, so the amazing ClearOffice Excel control is overkill for my needs (and I'm not sure if they support frozen columns/rows).

Most data grids (including the WPF Toolkit DataGrid control as well as several other commercial data grids) are based on ItemControl and are optimized for displaying tabular data using data binding of object properties, rather than a flexible grid control with independent cells.

What is the basic control layout and implementation strategy to build a spreadsheet-like control? Is it a Grid and code to dynamically manipulate the grid column widths and heights (to implement the frozen column/row feature)?