Syntax

on selectionChange
  answer "Selected:" && line (the selectedLine of me) of me
end selectionChange

Explanation

Text Fields

This message is sent when the selection range or cursor position in a text field changes.

Buttons

When a different choice is selected from a popup button, this message is sent.