Set cell edit dynamic according to the corresponding row

Posted by: viethdhe130200 on 5 January 2022, 12:50 am EST

    • Post Options:
    • Link

    Posted 5 January 2022, 12:50 am EST - Updated 3 October 2022, 3:11 am EST

    I have multiple rows in table flexgrid ( wijmo ), column 2 and column 3 will set edited dynamic. We has a param “editCell”. If editCell = 1 then cell are contained inside column 2 of row will be edited. If editCell = 2 then cells are contained inside column 3 of row will be edited. So, how to set dynamic edit for cells are contained inside column 3 or column 2 will be edited according to the corresponding row. Help me, pls. Thank you for reading my question

  • Posted 5 January 2022, 11:09 pm EST

    Hello,

    To achieve this you will need to handle the beginningEdit event of the FlexGrid, you can check the value of the previous cell and cancel the event if required. Please refer to the sample link below demonstrating the same:

    https://jscodemine.grapecity.com/share/ZOirwqeyXEekftD_pEg-Dg/

    Regards

  • Posted 6 January 2022, 2:16 am EST

    Thank you for answer. I have a question:

    I use this.flexGrid.keyActionEnter = wjGrid.KeyAction.CycleEditable. But when I collapsed then wjGrid.KeyAction.CycleEditable not working in row I collapsed

    Can you help me or suggest a solution for that? Thank you very much!

  • Posted 6 January 2022, 7:07 pm EST

    Hello,

    Sorry but we are unable to replicate the issue at our end, Would you please clarify if you are facing the issue with the shared sample too? If yes, please share some screenshots/gif of the issue or error. If you are facing this issue only in your application but not in the shared sample then it is possible that the issue is arising due to some code specific to your application. Since we are unable to replicate the issue, I would request you to share a sample that demonstrates the issue so that we could further investigate the root cause of the issue and assist you accordingly.

    Also please make sure that the columns or grid doesn’t have is isReadOnly property set to true as KeyActionEnter only moves the selection to the next editable column.

    Sample link: https://stackblitz.com/edit/js-sfcymf?file=index.js

    Regards

  • Posted 9 January 2022, 7:02 pm EST

    Thank you for answer

Need extra support?

Upgrade your support plan and get personal unlimited phone support with our customer engagement team

Learn More

Forum Channels