question

Upvotes
Accepted
322 11 16 21

Event listener with Grid API

How do I add a click event listener to grid element and get the clicked cell?

#technology#productapievents
icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Hello @LarryT

Thank you for your participation in the forum. Is the reply below satisfactory in resolving your query?


If so please can you click the 'Accept' text next to the appropriate reply? This will guide all community members who have a similar question.

Thanks,


AHS

Please be informed that a reply has been verified as correct in answering the question, and has been marked as such.

Thanks,
AHS

1 Answer

· Write an Answer
Upvotes
Accepted
21 0 0 0

You can directly use `addEventListener` method to add an event listener to grid element, just like other native elements. To obtain grid cell and other information from `MouseEvent` argument, use `getRelativePosition` method from Grid api. For more information, see this page (https://refinitiv.github.io/efx-grid/book/en/general_concept/event-listeners.html).

icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Dear Developers team

i'm not able to get the github page indicated abode, can you please help me to get related content please.

Regards


Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.