Kbase 18873: How to Eliminate Carriage Return from Editor in a Frame
Autor |
  Progress Software Corporation - Progress |
Acesso |
  Público |
Publicação |
  15/10/2008 |
|
Status: Verified
GOAL:
How to eliminate carriage return from editor in a frame
FIX:
Specifically, how to eliminate the carriage returns and line feeds that are displayed in a frame when the text comes from an editor widget.
In the Procedure Editor type the following code:
DEF VAR t-editor AS CHAR NO-UNDO.
DEF VAR x AS CHAR NO-UNDO.
DEF VAR y AS CHAR NO-UNDO.
UPDATE
t-editor
VIEW-AS EDITOR INNER-CHARS 60 INNER-LINES 5
WITH FRAME a.
t-editor = REPLACE(t-editor, chr(10), " "). /*carriage return*/
t-editor = REPLACE(t-editor, chr(13), ""). /*line feed*/
display
t-editor view-as text
with frame b.
When the program is running input some text, hit enter, enter some more text.
Notice that the text displayed in frame b does not include the carriage return.