Posted by: johngiblin on 28 October 2020, 7:12 am EST

    • Post Options:
    • Link

    Posted 28 October 2020, 7:12 am EST

    Is there a way to edit one cell at a time with the DataViewJS?



  • Posted 29 October 2020, 1:34 am EST

    Hi Jhon,

    You may use editMode to edit a single cell at a time. Please refer to the following code snippet and the attached sample that demonstrates the same.

    let dv = new GC.DataViews.DataView(
    new GC.DataViews.GridLayout({
    allowColumnResize: true,
    allowColumnReorder: false,
    showRowHeader: false,
    editUnit: "cell",
    selectionUnit: "cell",
    allowEditing: true,
    editMode: "inline"



    Editing Demo:



  • Posted 29 October 2020, 3:20 am EST

    That is exactly what I was looking for.

    I see in the onEditing what the row is being editted, but I do not see how to get the column. Is there a way to get the column as well

  • Posted 2 November 2020, 1:09 am EST


    You may use getSelections method for getting the column. Please refer to the following code snippet and let us know if you face any issues.

    dv.editing.addHandler((args) => {

    API Refrences:




  • Posted 2 November 2020, 2:22 am EST

    Thank you Avinash.

  • Posted 9 December 2020, 7:56 am EST

    So the dv.getSelections()[0].columns[0] was able to get me the column, but if I use the tab, it keeps the 1st row selected and this method will return me the original cell

    I need to be able to determine the column that is being editted when tabbed into

  • Posted 9 December 2020, 6:44 pm EST

    Hi John,

    We are able to replicate the issue at our end hence we have forwarded it to the concerned team for further investigation. We will update you regarding this as soon as we get any information. The internal ID for this issue will be JSVIEW-698.



  • Posted 10 December 2020, 2:14 am EST

    I was able to add a focuschange handler

    private focusChangedDataView(sender: any, args: any): void {
        this.currentColumn = args.column;
        // console.log(args);
  • Posted 16 December 2020, 12:15 am EST

    Hi John,

    The Dev team is curious about your use case. Could you please provide a use case. the team just wants to know what kind of functionality you are trying to achieve by getting the currently editing Cell.



  • Posted 16 December 2020, 12:18 am EST

    Hi John,

    We are glad to know the issue has been resolved at our end. Please feel free to contact me if you have any further queries. Further, we will update you regarding the SelectionChanged with tab issue here.



Need extra support?

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

Learn More

Forum Channels