5 Answers, 1 is accepted
0
Hi Jürgen Schweiss,
We have an online example which demonstrates exactly this. Please check it here:
Data Source change notifications
Sincerely yours,
Veselin Vasilev
the Telerik team
We have an online example which demonstrates exactly this. Please check it here:
Data Source change notifications
Sincerely yours,
Veselin Vasilev
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
0
juergen
Top achievements
Rank 1
answered on 01 Sep 2010, 11:35 AM
Hello Veselin,
in that example, having known columns (AutoGenerateColumns = "false") and their bindings. In my special case i'm using (AutoGenerateColumns = "true"). Therefore the textbox can't be bound to a single (known) column.
The textbox should be used as additional "editable" area for each user selected cellcontent in editmode.
regards,
Juergen
in that example, having known columns (AutoGenerateColumns = "false") and their bindings. In my special case i'm using (AutoGenerateColumns = "true"). Therefore the textbox can't be bound to a single (known) column.
The textbox should be used as additional "editable" area for each user selected cellcontent in editmode.
regards,
Juergen
0
Hi,
You can access auto-generated columns (and their bindings) in AutoGeneratingColumn event.
Sincerely yours,
Vlad
the Telerik team
You can access auto-generated columns (and their bindings) in AutoGeneratingColumn event.
Sincerely yours,
Vlad
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
0
juergen
Top achievements
Rank 1
answered on 02 Sep 2010, 09:38 AM
Hi,
my problem consists of having implemented an automatic FullRow/Cell switching, as suggested here in another forum post.
http://www.telerik.com/community/forums/wpf/gridview/excel-like-cell-row-and-column-selection.aspx
There is a possible caveat though - when you switch to row selection all selected cells will be cleared and I am not sure if this behavior is desired. Similarly, all selected items will be cleared when you switch from row selection to cell selection.
In your documentation i found following:
"di" is my dataItem (which consists of 4 cols) of the current row. "colname" could not be achieved,
because CurrentCellInfo is beeing null.
How to achieve the actual ColumnName in the suitable event?
regards,
Juergen
my problem consists of having implemented an automatic FullRow/Cell switching, as suggested here in another forum post.
http://www.telerik.com/community/forums/wpf/gridview/excel-like-cell-row-and-column-selection.aspx
There is a possible caveat though - when you switch to row selection all selected cells will be cleared and I am not sure if this behavior is desired. Similarly, all selected items will be cleared when you switch from row selection to cell selection.
In your documentation i found following:
SelectedItem
To access the data item of the selected row use the SelectedItem property. It changes its value every time when the row selection changes and exposes the object to which the row is bound. You can use it when the SelectionUnit is set to FullRow (default), otherwise it is null.
CurrentItem
The CurrentItem property holds the data item of the row which currently holds the focus. It may or may not coincide with the selected row. However, in most of the cases these two rows are one and the same.
//GridViewCellInfo and stores two pieces of data – the Item and the Column that a particular cell is associated with
var ci =
this
.grdView.CurrentCellInfo;
string
colname = ci.Column.UniqueName;
if
(di !=
null
)
{
Binding myBinding =
new
Binding()
{
Source = di,
Path =
new
PropertyPath(colname),
Mode = BindingMode.TwoWay
};
this
.txtCellContent.SetBinding(TextBox.TextProperty, myBinding);
}
"di" is my dataItem (which consists of 4 cols) of the current row. "colname" could not be achieved,
because CurrentCellInfo is beeing null.
How to achieve the actual ColumnName in the suitable event?
regards,
Juergen
0
juergen
Top achievements
Rank 1
answered on 02 Sep 2010, 02:04 PM
Hi,
using CurrentCellChanged-Event with CellInfo.Item solved this.
Thanks,
Jürgen
using CurrentCellChanged-Event with CellInfo.Item solved this.
Thanks,
Jürgen