wpf controls - Showing a new Window right next to a DataCell in DataGrid (WPF) -


i want scenario when user clicks on cell in datagrid in wpf, want open numpad next (this touch based input). numpad, understand separate window.

1) how can know cell selected
2) how can show numpad next cell?
3) how can find coordinates of cell position numpad?
4) how can set value of cell based on numpad entry?

numpad wpf user control in same application. datagrid .net 4 control. it's normal windows desktop application

this not trivial task , should have knowledge of wpf accomplish this, here ideas might for:

  1. the datagridcell.isselected property tells whether cell selected.
  2. i use popup show numpad directly besides cell.
  3. if use popup not need coordinates, can specify relative placement using popup.placement property. see msdn document: popup placement behavior
  4. you try use binding numpad user control in datagridcell.

using datagrid.cellstyle or datagridcolumn.cellstyle property can specify alternate style cells of datagrid or specific column. within style, change template , add popup opened if current cell selected. can achieve binding popup.isopen property datagridcell.isselected property.

this initial idea. still have have @ provided msdn links , read other stuff wpf. although might take time learn 'wpf way' (i.e. xaml), (in eyes) easier using lots of code-behind determine selected cell, positioning control @ correct location, transferring data numpad cell , on...


Comments

Popular posts from this blog

Javascript line number mapping -

c# - Is it possible to remove an existing registration from Autofac container builder? -

php - Mysql PK and FK char(36) vs int(10) -