Skip to Content

Catch line modification in a Grid

Hello,

I'm using a Grid in a form, and I have massive updates. In order to optimize performance, I'm looking to a way to catch the event in the line (of the Grid) that was modified by the user, and then do the update only for this specific line. Has anyone used this before ?

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

2 Answers

  • Dec 01, 2016 at 03:22 PM

    Hi Abdel,

    If you are listening the itemEvent from SAP B1, you can do something like this:

                if(pVal.ItemChanged && pVal.ItemUID.Equals("your grid id"))
                {
                    Debug.WriteLine(string.Format("ItemChanged [{0}]. Line [{1}]. Event [{2}]", pVal.ColUID, pVal.Row, pVal.EventType.ToString()));
                    //do your logic
                }
    

    Hope it helps.

    Kind Regards,

    Diego Lother

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Dec 15, 2016 at 01:06 PM

    Hi Abdel,

    This is long procedure but may help you-

    Maintain integer array which stores linenum of grid on et_KEY_DOWN event. You can use this array for update query.

    Thanks,

    Zuber

    Add comment
    10|10000 characters needed characters exceeded