Removing "Click here to add new row"

12 posts, 1 answers
  1. Christopher
    Christopher avatar
    17 posts
    Member since:
    Sep 2008

    Posted 11 Sep 2008 Link to this post

    I've looked around, but I can't seem to find either a text property to change the text, or a property to just hide the auto-created "Click here to add new row" Row in an empty GridView.

    I'm using a RadGridView control to display data that comes from a hand held scanner and is created on the fly.  Because of this, I have no data source for the grid, I just define the columns and use AddRow() to display my data. The grid also allows editing of the data in the gird before saving.

    Is there a way to turn this off?


  2. Answer
    Nick
    Admin
    Nick avatar
    767 posts

    Posted 12 Sep 2008 Link to this post

    Hi Christopher,

    Thank you for the questions.

    In order to turn off the new row visual element, you should set AllowAddNewRow property of MasterGridViewTemplate to false from either the property grid in Visual Studio or programmatically as shown below:
     
    this.radGridView1.MasterGridViewTemplate.AllowAddNewRow = false

    If you want to change add new row default text, please refer to the following knowledge base article - RadGridView Localization.

    Feel free to contact me, if you have any further questions.

    Best wishes,
    Nick
    the Telerik team

    Check out Telerik Trainer, the state of the art learning tool for Telerik products.
  3. UI for WinForms is Visual Studio 2017 Ready
  4. Christopher
    Christopher avatar
    17 posts
    Member since:
    Sep 2008

    Posted 12 Sep 2008 Link to this post

    Thanks for the response.  I actually fiured this out earlier today.  I was under the impression that you had to have that property turned on in order to add rows properly.

    I'm still very new to the Telerik Controls as I'm sure you can guess.
  5. Santiago
    Santiago avatar
    18 posts
    Member since:
    Nov 2007

    Posted 12 Jan 2009 Link to this post

    Sorry, but I don't understand the code sample.
    I mean, which property of radgrid has localization values?? which is the necessary namespace to implement RedGridLocalizationSettings??

    Thanks.
  6. Ramius
    Ramius avatar
    127 posts
    Member since:
    Feb 2008

    Posted 12 Jan 2009 Link to this post

    Hello Santiago,

    the necessary namespace to implement RadGridLocalizationSettings is:

     Telerik.WinControls.UI.Localization

    Greetings,

    Ramius
  7. Nick
    Admin
    Nick avatar
    767 posts

    Posted 12 Jan 2009 Link to this post

    Hi Santiago,

    Thank you for sharing your knowledge with the community, Ramius.

    I would like to give a link to a documentation topic about localization which may be useful too.

    Sincerely yours,
    Nick
    the Telerik team

    Check out Telerik Trainer, the state of the art learning tool for Telerik products.
  8. Santiago
    Santiago avatar
    18 posts
    Member since:
    Nov 2007

    Posted 12 Jan 2009 Link to this post

    Yes but, I don't know why I dont have these assembly. In Telerik.WinControls.UI I have only is

    Design, Grid, Layouts, Menu, Multimedia, properties and tabstriip. I am using telerik radcontrols for winforms q2 2007.
  9. Nick
    Admin
    Nick avatar
    767 posts

    Posted 13 Jan 2009 Link to this post

    Hello Santiago,

    You need the following four assemblies to use RadGridView: TelerikCommon, Telerik.WinControls, Telerik.WinControls.UI, Telerik.WinControls.GridView. So you need Telerik.WinControls.GridView assembly reference in your application too.

    Unrelated to your question, you are using a very old version of our controls so you lack a lot of improvements and fixes. We are going to release a new version this month - Q3 2008 SP2. I strongly suggest that you consider upgrading. We are going to help you in the upgrade process.

    Greetings,
    Nick
    the Telerik team

    Check out Telerik Trainer, the state of the art learning tool for Telerik products.
  10. Praveen
    Praveen avatar
    5 posts
    Member since:
    Jun 2008

    Posted 03 Jun 2009 Link to this post

    hi ,

    I am facing problem with "Allowaddnewrow" is set to true,the thing is when i click on Perticular cell
    and Press Enter ,Empty Value Cell(row) is Adding at last in the radgridview,so i dont want to add that
    like that,can u suggest me...............

  11. Nick
    Admin
    Nick avatar
    767 posts

    Posted 03 Jun 2009 Link to this post

    Hi Praveen,

    Thank you for contacting us. Unfortunately, I cannot understand completely your scenario. Perhaps you need DefaultValuesNeeded event to set default values for some (all) of your cells when you add a new row.

    Sincerely yours,
    Nick
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Check out the tips for optimizing your support resource searches.
  12. Praveen
    Praveen avatar
    5 posts
    Member since:
    Jun 2008

    Posted 03 Jun 2009 Link to this post

    When "Allowaddnewrow" is set to true,

    i have two Cells in RADGRIDVIEW,one  radcheckbox and other cell is  radtextbox,
    when i enter some thing in radtextbox and press enter,the newly enter value will be added as row at last in radgridview
    its ok,
    now if i dont enter any thing in that Cell and Press Enter that Empty Cell is added
    at last as a row.....i dont want to happen like that...

    ,can u suggest me what i have to do...............

  13. Nick
    Admin
    Nick avatar
    767 posts

    Posted 05 Jun 2009 Link to this post

    Hello Praveen,

    We cannot reproduce the problem. Please download the latest trial version of our controls and write us back if the issue persists.

    Sincerely yours,
    Nick
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Check out the tips for optimizing your support resource searches.
Back to Top
UI for WinForms is Visual Studio 2017 Ready