datagridtemplatecolumn

Dynamic DataGrid columns in WPF DataGrid based on the underlying set of data (and their type)

Hello everyone, I've got kind of a conceptual question. I am in the process of wrapping some statistics classes I wrote into WPF. For that I have two DataGrid(-Views, currently in WinForms). In one DataGrid each row represents a column in the other. There I can set-up different variables (as in mathematical/statistical variables) with...

WPF DataGridTemplateColumn shared template?

Hi I have a datagrid that has a number of datagridtemplate columns that are all identical apart from they each have a different datacontext on the template's stackpanel. <toolkit:DataGridTemplateColumn Header="Col 1"> <toolkit:DataGridTemplateColumn.CellTemplate> <DataTemplate> ...

Silverlight DataGridTemplateColumn vs. DataGridTextColumn

Why does this work... <data:DataGridTemplateColumn Header="YTD v. Exchange" x:Name="YTDvExchange" Visibility="Collapsed" CanUserSort="True" SortMemberPath="ytdExchangeReturn.value"> <data:DataGridTemplateColumn.CellTemplate> <DataTemplate> <TextBlock TextAlignment=...

Silverlight 4 datagrid and Selecting All Checkboxes when select the Group Header CheckBox

Hi, I have a datagrid with Grouping ON and whose first col is a Checkbox. I'm looking to have the CheckBox on the Group Level so that the User click one checkbox and it automatically select all the checkboxes under that groud and vicevera. I also have a Print button which when pressed should have arary of all the rows with CheckBox chec...

Custom DataGrid column with a CellTemplate and binding

I need to create a reusable DataGrid column with a custom CellTemplate. This CellTemplate should, among other things, contain a TextBlock control to which I need to bind values to display in the DataGrid. All examples I've seen so far specified the CellTemplate for a column directly when using it in a DataGrid's Columns property and also...

EditingCommands of the WPF RichTextBox loose its binding when they are not put within a ToolBar

Using the below code in a DataGridTemplateColumn of the DataGrid, my formatting buttons are disabled(grayed out). The formatting buttons are only enabled when they are put in a ToolBar. When the buttons are put in a ToolBar I do not need the CommandTarget. So when I put them outside a ToolBar some could think it must work with CommandTa...

ASP.NET : Access controls declared in TemplateColumn of DataGrid

ASCX File: <asp:datagrid runat="server" id="gridFormFields" datakeyfield="FieldID" autogeneratecolumns="False" onitemcommand="gridFormFields_ItemCommand" onitemdatabound="gridFormFields_ItemDataBound"> <columns> <asp:templatecolumn> <itemtemplate> <asp:imagebutton runat="server" id="buttonMoveUpFormField" resour...

Resizable datagrid is not consistent in rendering its background image

Hi Guys, I have a datagrid in silverlight, it contains two template columns, i set a background image in each one of them. I made this datagrid resizable using codebehind logic. I have done my calculations in double values so that no fractional space is left in the grid. What I want is that my datagrid should not show any vertical line...

Binding to DataGridTemplateColumn

hi, I have a User table and I have a foreign key of this table from a Book table. the FK is ProxyResponsibleUser_ID. when I use DataGridTextColumn in my DataGrid anything is OK but now I want to use DataGridTemplateColumn to display the FullName column from User table for corresponding user with ProxyResponsibleUser_ID. I get an error s...

WPF DataTemplateColumn access DataTemplate and set ItemsSource

I know its strange what I am doing but I want this to work. I am going wrong somehwere I feel. I have a DataTemplate defined in my resources as follows : <UserControl.Resources> <ResourceDictionary> <ResourceDictionary.MergedDictionaries> <ResourceDictionary Source="../ParameterEditorResourceDictionary.xaml"><...

WPF DataGrid: Automatically re-sort on a DataGridTemplateColumn

In WPF's DataGrid control, if you set a column to one of the default column types (like DataGridTextColumn or DataGridCheckBoxColumn), sort on that column, and then change its value, the grid will automatically be re-sorted. However, if you use a DataGridTemplateColumn (and allow the column to be sorted), it can be sorted, but changing ...

Silverlight Datagrid: Setting background of a template cell with custom behavior

I have a custom DataGrid mixed with DataGridTemplateColumns and a custom behavior derived from this answer http://stackoverflow.com/questions/3970363/silverlight-datagrid-highlight-an-entire-column-when-that-column-is-sorted. The problem I'm experiencing is that any DataGridTemplateColumn's cells are not picking up the 'highlight'. The c...