new row

4 posts, 1 answers
  1. Mihai Velicu
    Mihai Velicu avatar
    16 posts
    Member since:
    Nov 2009

    Posted 01 Apr 2010 Link to this post

    Hi !
    I have a grid with first 2 columns read only and more other ReadWrite.


    When I "Click here to add new row " and I click somewhere on the direction of these 2 columns Readonly, the DefaultValueNeeded event is not triggered .If I click on the direction where I have read write columns , this DefaultValueNeeded event is triggered.

    Is this behavior normal ?

    Regards,
    Mihai

  2. Answer
    Julian Benkov
    Admin
    Julian Benkov avatar
    1135 posts

    Posted 07 Apr 2010 Link to this post

    Hello Mihai Velicu,

    Yes, this is normal, because the new row is created when one or more of editors in the new row are open for the first time. The ReadOnly column cannot open an editor and cannot create the new row.
     

    Best wishes,
    Julian Benkov
    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.
  3. UI for WinForms is Visual Studio 2017 Ready
  4. Ellis
    Ellis avatar
    28 posts
    Member since:
    Jun 2007

    Posted 14 Jun 2010 Link to this post

    Hi,
     probably someoneelse already ask it but i didn't find the right post.

    In my grid the first column is a commandcolumn. I use it for open a modal form, to chose the Article from the Warehouse.
    When i choose it, i update some columns, like price, max quantity, idarticle, etc
    But if i try to insert a new row in this way, i got an error.
    In your post you say "the new row is created when one or more of editors in the new row are open for the first time".
    I can't do this, because the first operation is to chose the Article.
    How can i solve this problem? There is a way to fire the command it creates the row?

     
        Private Sub RadGridView1_CommandCellClick(ByVal sender As System.ObjectByVal e As System.EventArgs) Handles RadGridView1.CommandCellClick 
    ' I chose the article from warehouse 
    '... 
    ' Then i set data in row from selected article 
                    RadGridView1.CurrentRow.Cells("IdArticle").Value = IdArticle 
                    RadGridView1.CurrentRow.Cells("Quantity").Value = Quantity 
                    RadGridView1.CurrentRow.Cells("Price").Value = Price 
                    RadGridView1.CurrentRow.Cells("DataMovimento").Value = Date.Today 
            End If 
        End Sub 

    Thank you

    Ellis
  5. Nikolay
    Admin
    Nikolay avatar
    1804 posts

    Posted 21 Jun 2010 Link to this post

    Hi Ellis,

    Please find the answer to your question in the following forum thread:
    http://www.telerik.com/community/forums/winforms/gridview/create-new-row-on-commandcolumn-click.aspx

    All the best,
    Nikolay
    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
Back to Top