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

Grid - Add new record / Refresh

4 Answers 88 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Jun Ting
Top achievements
Rank 1
Jun Ting asked on 28 May 2010, 02:22 AM
How to change the text "Add new record" to "Add More"? Is it possible to remove the REFRESH button?

4 Answers, 1 is accepted

Sort by
0
Shinu
Top achievements
Rank 2
answered on 28 May 2010, 06:22 AM

Hello,

The following settings will help you in achieveing the required.

ASPX:

 
 . . .  
<MasterTableView CommandItemDisplay="Top"  AutoGenerateColumns="False" DataSourceID="SqlDataSource1">  
    <CommandItemSettings AddNewRecordText="Add more..." ShowRefreshButton="false" />  
 . . . 

-Shinu.

0
Jun Ting
Top achievements
Rank 1
answered on 31 May 2010, 09:09 AM

Hi,

Added the code, but it give me error:

" Type 'Telerik.Web.UI.GridCommandItemSettings' does not have a public property named 'ShowRefreshButton'."

  <MasterTableView Width="100%" CommandItemDisplay="TopAndBottom" DataKeyNames="pollAnswerID" HorizontalAlign="NotSet" AutoGenerateColumns="False">  
                <CommandItemSettings AddNewRecordText="Add more..." ShowRefreshButton="false" />  
0
Daniel
Telerik team
answered on 31 May 2010, 01:38 PM
Hello Jun,

Please examine the following thread:

Hide Refresh button on CommandItemDisplay


Regards,
Daniel
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
Jun Ting
Top achievements
Rank 1
answered on 01 Jun 2010, 07:15 AM
Added the code as below, but the Refresh button still showing.
    Protected Sub gNew_ItemCreated(ByVal sender As Object, ByVal e As GridItemEventArgs)  
        'Hide refresh button  
        If TypeOf e.Item Is GridCommandItem Then  
            e.Item.FindControl("RefreshButton").Parent.Visible = False 
        End If  
    End Sub 
Tags
Grid
Asked by
Jun Ting
Top achievements
Rank 1
Answers by
Shinu
Top achievements
Rank 2
Jun Ting
Top achievements
Rank 1
Daniel
Telerik team
Share this question
or