This is a migrated thread and some comments may be shown as answers.

Gridview add new mode tooltip

2 Answers 36 Views
GridView
This is a migrated thread and some comments may be shown as answers.
Bao
Top achievements
Rank 1
Bao asked on 20 Jul 2017, 03:35 PM

Hi ,

When i click to the line "Click here to add new row" on grid view. It will enter to add new mode. Can i put one more row above a new row like "Please press enter to save" and a new row will be below. Because i want to guide the customer know how to save the new row. Can i do that or some way like that ?

 

Thanks.

2 Answers, 1 is accepted

Sort by
0
Accepted
Dess | Tech Support Engineer, Principal
Telerik team
answered on 21 Jul 2017, 08:06 AM
Hello Bao, 

Thank you for writing.  

You can specify a tooltip for the new row by using the ToolTipTextNeeded event:
public RadForm1()
{
    InitializeComponent();
 
    DataTable dt = new DataTable();
    dt.Columns.Add("Id", typeof(int));
    dt.Columns.Add("Name", typeof(string));
    for (int i = 0; i < 10; i++)
    {
        dt.Rows.Add(i, "Item" + i);
    }
 
    this.radGridView1.DataSource = dt;
    this.radGridView1.AutoSizeColumnsMode = Telerik.WinControls.UI.GridViewAutoSizeColumnsMode.Fill;
 
    this.radGridView1.ToolTipTextNeeded += radGridView1_ToolTipTextNeeded;
}
 
private void radGridView1_ToolTipTextNeeded(object sender, Telerik.WinControls.ToolTipTextNeededEventArgs e)
{
    if (sender is GridNewRowElement)
    {
        e.ToolTipText = "Pleas press Enter to save";
    }
}

I hope this information helps. Should you have further questions I would be glad to help.

Regards,
Dess
Progress Telerik
Try our brand new, jQuery-free Angular 2 components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
0
Bao
Top achievements
Rank 1
answered on 22 Jul 2017, 05:17 AM
Thank you so much.
Tags
GridView
Asked by
Bao
Top achievements
Rank 1
Answers by
Dess | Tech Support Engineer, Principal
Telerik team
Bao
Top achievements
Rank 1
Share this question
or