Question

How to get current element of list by javascript. The element clicked by three dots. Please help. From the Sharepoint list called "Stuff".

And after click on three dots i want to get a ID of element. Please help.

Était-ce utile?

La solution

You can use the SP.ListOperation.Selection.getSelectedItems() method to get the items ID.

The code would be as below:

var selectedItem = SP.ListOperation.Selection.getSelectedItems()[0].id;

enter image description here

Licencié sous: CC-BY-SA avec attribution
Non affilié à sharepoint.stackexchange
scroll top