jQuery UI Widgets Forums Grid How to add new row in custome row

This topic contains 1 reply, has 2 voices, and was last updated by  Stanislav 7 years, 2 months ago.

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
  • How to add new row in custome row #95899

    hahakunge
    Participant

    Hi jqWidgets team!

    Assume that I have a grid with two column,Like below
    Value Code
    a    001
    b 101

    When I add a row with data {Value:c, Code:002},
    the grid should be like this and select the added row

    Value Code
    a 001
    c 002
    b 101

    The added row found its position according to column Code,

    I have read the documentation.And the API only afford a way to add at the first or the last line.
    I tried to figure it out with “updatebounddata”(with parameter ‘cells’ or ‘data’) and “sortby”,
    but it cost about 2 seconds when the grid has 900 row’s data

    Can you tell me another way to achieve the demand or give me some suggestion on improving the performance?

    Thanks very much!!!

    How to add new row in custome row #95965

    Stanislav
    Participant

    Hello hahakunge,

    Unfortunately, what you are asking for cannot be done, a row can only be inserted at the beginning or the end(first and last line).

    I suggest looking through this example, you might find it helpful:
    https://www.jqwidgets.com/community/topic/insert-row-at-particular-position/

    Best Regards,
    Stanislav

    jQWidgets Team
    http://www.jqwidgets.com/

Viewing 2 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic.