Difference between revisions of "Lua:writeToClipboard"

From Cheat Engine
Jump to navigation Jump to search
(Created page with "<p>writeToClipboard(text): Writes the given text to the clipboard</p>")
 
m (Added CodeBox Template.)
 
Line 1: Line 1:
<p>writeToClipboard(text): Writes the given text to the clipboard</p>
+
[[Category:Lua]]
 +
{{CodeBox|'''function''' writeToClipboard(''text'') ''':''' void}}
 +
 
 +
Writes the given text to the clipboard.
 +
 
 +
===Function Parameters===
 +
{|width="85%" cellpadding="10%" cellspacing="0" border="0"
 +
!align="left"|Parameter
 +
!align="left"|Type
 +
!style="width: 80%;background-color:white;" align="left"|Description
 +
|-
 +
|text
 +
|String
 +
|The text to be copied to the system clipboard.
 +
|}
 +
 
 +
===Returns===
 +
void — This function does not return any value.
 +
 
 +
===Examples===
 +
<pre>
 +
writeToClipboard("Hello World")
 +
-- Now you can paste "Hello World" into any text field using Ctrl+V or similar
 +
</pre>
 +
 
 +
{{LuaSeeAlso}}

Latest revision as of 23:48, 4 December 2025

<> Function

function writeToClipboard(text) : void

Writes the given text to the clipboard.

Function Parameters[edit]

Parameter Type Description
text String The text to be copied to the system clipboard.

Returns[edit]

void — This function does not return any value.

Examples[edit]

writeToClipboard("Hello World")
-- Now you can paste "Hello World" into any text field using Ctrl+V or similar

See also[edit]

Lua
Script Engine