Type function Return value none Revision Release 2022.3683 Keywords copy, pasteboard See also Pasteboard pasteboard.paste() pasteboard.clear()
Copies a string, URL, or image to the device pasteboard.
Image copying/pasting is only supported on iOS.
pasteboard.copy( copyType, string ) pasteboard.copy( copyType, url ) pasteboard.copy( copyType, fileName, baseDir )
String. The type of data to copy to the pasteboard. Valid options include "string"
, "url"
, or "image"
.
String. The string you wish to copy to the pasteboard. Applies only if copyType
is "string"
.
String. The URL you wish to copy to the pasteboard. Applies only if copyType
is "url"
.
String. The file name of the image you wish to copy to the pasteboard. Applies only if copyType
is "image"
. Note that image copying/pasting is only supported on iOS.
local pasteboard = require( "plugin.pasteboard" ) pasteboard.copy( "string", "Hello World!" )