Zurück zum Blog

Copy and paste to clipboard

von Tobias Arnhold

Well I had the requirement to copy the content of a textarea into the clipboard. There are two ways to do that:

  1. Build a dynamic action with custom JavaScript code: Copy Text to Clipboard

    Code example, with a dynamic action on Click and Execute JavaScript Code:

    /* Select the text field */
    $('#P1_APEX_ITEM').select();
    /* Copy the text inside the text field */
    document.execCommand("copy");
  2. Use an APEX plugin: Copy to Clipboard (v1.1), built by Dick Dral.

Icon made by Vitaly Gorbachev from www.flaticon.com, licensed under CC 3.0 BY.

ACT! IT entwickelt und betreut Anwendungen mit Oracle APEX. Was wir als Oracle APEX Dienstleister tun

Zuerst erschienen auf apex-at-work.blogspot.com