Hello,
i created a custom cell element.
The custom part of the Element is a RadListControl.
The functionality works but I want the ListControl Element fit perfect in the Cell.
I have tried a lot and read many forum threads to find a solution but nothing works.
There are still Gaps (see Screenshot).
I hope someone can help me quick with my request.
Greets André
5 Answers, 1 is accepted
0
Hi Andre,
Thank you for writing.
You can use RadListElement instead. For example:
Another example for this is available here: Creating custom cells.
Let me know if I can assist you further.
Regards,
Dimitar
Telerik
Thank you for writing.
You can use RadListElement instead. For example:
class MyGridDataCellElement : GridDataCellElement{ public MyGridDataCellElement(GridViewColumn column, GridRowElement row) : base(column, row) { } protected override void CreateChildElements() { base.CreateChildElements(); RadListElement list = new RadListElement(); for (int i = 0; i < 3; i++) { list.Items.Add(new RadListDataItem("item " + i)); } this.Children.Add(list); }}Another example for this is available here: Creating custom cells.
Let me know if I can assist you further.
Regards,
Dimitar
Telerik
Check out the Windows Forms project converter, which aids the conversion process from standard Windows Forms applications written in C# or VB to Telerik UI for WinForms.For more information check out this blog post and share your thoughts.
0
Ahmed
Top achievements
Rank 1
answered on 30 May 2016, 02:42 PM
Dear Dimitar,
is there is a way to change the dropdownlist items.
for example i need each dropdownlist contains different items based on its row id value
Regards,
Ahmed
0
Hi Andre,
Thank you for writing back.
You can override the SetContentCore method and set the items there:
I hope this will be useful.
Regards,
Dimitar
Telerik
Thank you for writing back.
You can override the SetContentCore method and set the items there:
protected override void SetContentCore(object value){ base.SetContentCore(value); var rowId = (int) this.RowInfo.Cells[0].Value; list.Items.Clear(); for (int i = 0; i < rowId/10; i++) { list.Items.Add(new RadListDataItem("item " + i)); }}I hope this will be useful.
Regards,
Dimitar
Telerik
Check out the Windows Forms project converter, which aids the conversion process from standard Windows Forms applications written in C# or VB to Telerik UI for WinForms.For more information check out this blog post and share your thoughts.
0
Gopinath
Top achievements
Rank 1
answered on 21 Jun 2016, 08:16 AM
HI
Thanks in advance.
I need help in gridview, i have to create a date control and combo in a different cell in the same column.
pl can u send me a small project using radgridview and create the above.
Regards
Gopinath
0
Date: 6/21/2016 4:52:40 AM
Hello Gopinath,
Thank you for writing.
If I understand correctly you want to show different editors in the same column. The following article shows how this can be achieved: Change the active editor depending on the cell value type. | UI for WinForms Documentation
I hope this will be useful.
Regards,
Dimitar
Telerik
Hello Gopinath,
Thank you for writing.
If I understand correctly you want to show different editors in the same column. The following article shows how this can be achieved: Change the active editor depending on the cell value type. | UI for WinForms Documentation
I hope this will be useful.
Regards,
Dimitar
Telerik
Check out the Windows Forms project converter, which aids the conversion process from standard Windows Forms applications written in C# or VB to Telerik UI for WinForms.For more information check out this blog post and share your thoughts.
