Kbase P107292: 4GL: How to check whether the user currently selected some text in an EDITOR widget?
Autor |
  Progress Software Corporation - Progress |
Acesso |
  Público |
Publicação |
  05/08/2005 |
|
Status: Unverified
GOAL:
4GL: How to check whether the user currently selected some text in an EDITOR widget?
FIX:
The following 4GL code check whether there is currently selected (Highlighted) text in the EDITOR widget named EDITOR-1. It messages the selection if any or informs the user that there is no text selected:
IF EDITOR-1:SELECTION-START NE EDITOR-1:SELECTION-END THEN
MESSAGE EDITOR-1:SELECTION-TEXT
VIEW-AS ALERT-BOX INFO BUTTONS OK.
ELSE
MESSAGE "No text is selected"
VIEW-AS ALERT-BOX INFO BUTTONS OK.