Mark Stevens
Top achievements
Rank 1
Mark Stevens
asked on 22 Mar 2018, 10:21 PM
I have a scenario where I need to allow users to edit the header text of the columns in my GridView. I'm not sure if this can be done but it would be nice to have the header text change to a text box when the user double clicks on the header.
4 Answers, 1 is accepted
0
Hello Mark,
I am afraid that this is not possible. I would recommend you to show a separate form and fill the header text there.
Please let me know if there is something else I can help you with.
Regards,
Dimitar
Progress Telerik
I am afraid that this is not possible. I would recommend you to show a separate form and fill the header text there.
Please let me know if there is something else I can help you with.
Regards,
Dimitar
Progress Telerik
Try our brand new, jQuery-free Angular components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
0
Mark Stevens
Top achievements
Rank 1
answered on 25 Mar 2018, 06:16 PM
Thanks Dimitrar,
I've found a workaround by creating a custom header(GridHeaderCellElement) and implemented a radTextboxElement to override the existing header.
That way a user clicks on the header and can change the header text.
0
Mark Stevens
Top achievements
Rank 1
answered on 25 Mar 2018, 08:40 PM
So I have the header using a RadTextBoxElement but I'm not sure how to update the Column.HeaderText property when I change the text in the RadTextBoxElement, any ideas?
0
Hi Mark,
Can you share your implementation so I can examine and test it locally?
In general, you can use the TextChanged event and update the text like this:
I am looking forward to your reply.
Regards,
Dimitar
Progress Telerik
Can you share your implementation so I can examine and test it locally?
In general, you can use the TextChanged event and update the text like this:
private
void
Textbox_TextChanged(
object
sender, EventArgs e)
{
this
.ColumnInfo.HeaderText = textbox.Text;
}
I am looking forward to your reply.
Dimitar
Progress Telerik
Try our brand new, jQuery-free Angular components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.