Copy to clipboard
Posted: 18 Oct 2018
Hi all,
I want to copy the text of a text field to the clipboard.
Apparently, the usual JavaScript way does not work.
In a button I have implemented the following code. Any idea what's wrong about it?
var copytext = fd.field('Status').control().value()
copytext.select();
document.execCommand("copy");
I have also tried to use the command fd.execCommand("copy") instead of document.execCommand("copy"), but it didn't work.
Thank you very much in advance for help!
I want to copy the text of a text field to the clipboard.
Apparently, the usual JavaScript way does not work.
In a button I have implemented the following code. Any idea what's wrong about it?
var copytext = fd.field('Status').control().value()
copytext.select();
document.execCommand("copy");
I have also tried to use the command fd.execCommand("copy") instead of document.execCommand("copy"), but it didn't work.
Thank you very much in advance for help!