I've made a button and I've a Display Only page item called P5_COPY
When I click on button , it should copy the value of P5_COPY
into clipboard .
Here what i did :
var str = apex.item('P5_COPY').getValue();
navigator.clipboard.writeText(str);
But it copied 'str'
not the value ! even the first line of code shows the value of page item .
Details about my dynamic action :
Event Scope : static
Type : immediate
event : click
Selection Type : JQuery selector
jQuery Selector : #P5_COPY
Where did I go wrong ?
Any help would be appreciated !