using SyntaxEditor in a DataGrid cell

SyntaxEditor for WPF Forum

Posted 10 years ago by Chris Thompson
Version: 9.1.0506
Avatar
Do you have any examples where the SyntaxEditor is used as a cell editor in the WPFToolkit DataGrid? Or do you have suggestions on how to go about doing that? Or do you not recommend using SyntaxEditor in that kind of scenario?

Comments (6)

Posted 10 years ago by Actipro Software Support - Cleveland, OH, USA
Avatar
Hi Chris,

What sort of thing would you be editing there? It seems like SyntaxEditor could be overkill for most scenarios within a grid. Also we don't yet have a single line edit mode (although that is a planned feature) so your SyntaxEditor instances would be multiline and probably taller than you want.

You should be able to embed a SyntaxEditor using the DataGridTemplateColumn though, which lets you put a SyntaxEditor in a DataTemplate.


Actipro Software Support

Posted 10 years ago by Chris Thompson
Avatar
I am looking at editing short snippets or rules presented as a table that can be edited right in the grid. Editing directly in the grid would be a convenience factor versus editing the rule/snippet in a separate panel.
Posted 7 years ago by Jon Heaton
Avatar

Could you please provide a sample of using the DataGridTemplateColumn with a SyntaxEditor in C#?

Posted 7 years ago by Actipro Software Support - Cleveland, OH, USA
Avatar

Hi Jon,

It would be the same as putting any other control within a DataGridTemplateColumn.  This URL talks about how to use the column:

http://windowsclient.net/wpf/wpf35/wpf-35sp1-toolkit-datagrid-feature-walkthrough.aspx

Since the columns require data binding for their contained controls, you'd need to activate the data binding features of SyntaxEditor (off by default) by following the steps in the "SyntaxEditor User Interface Features / Input/Output Features / Data Binding" documentation topic.


Actipro Software Support

Posted 7 years ago by Jon Heaton
Avatar

I am so sorry.  I am working in WinForms.  I realize this is in the wrong forum.  Any advice?

Posted 7 years ago by Actipro Software Support - Cleveland, OH, USA
Avatar

Sorry but we haven't worked with the WinForms DataGrid so unfortunately we don't have any tips for that.


Actipro Software Support

The latest build of this product (v2019.1 build 0683) was released 1 month ago, which was after the last post in this thread.

Add Comment

Please log in to a validated account to post comments.