Back

GetSharedText

JS Py
Hello World

Returns the value of a shared text.

app.GetSharedText() → String

If the result is returned, it cannot be read another time unless it is shared again.

See Also: GetSharedFiles, SendFile, SendText

Example - Show Shared Text

function OnStart()
{
    var text = app.GetSharedText();

    if( text ) app.Alert( text );
    else app.ShowPopup( "No shared text received." );
}
from native import app

def OnStart():
    text = app.GetSharedText()

    if text:
        app.Alert(text)
    else:
        app.ShowPopup("No shared text received.")
    Copy     Copy All       Run