Progress
Programming
Handbook


Text

On Windows, fill-in fields use extra space on the screen for border decorations. To save space for read-only text, you can view the value as a text widget rather than a fill-in. (If you want to preserve the native look, you can view it as a native fill-in but set the SENSITIVE attribute to FALSE.)

NOTE: You cannot update a field that is displayed as a text widget. Use the text widget only for read-only data (for example, report data or field labels).

You can use the following form of the VIEW–AS phrase to view a value as text:

SYNTAX
VIEW-AS TEXT [ size-phrase ] [ TOOLTIP tooltip ] 

The following code displays customer names as fill-ins.

FOR EACH customer:
  DISPLAY customer.name.
END. 

Notice the spacing between customer names in the resulting screen:

To eliminate this space, view the customer name as text.

FOR EACH customer:
  DISPLAY customer.name VIEW-AS TEXT.
END. 

When you run this code, the screen appears as follows:

You can specify that all fields in a frame be displayed as text rather than as fill-ins by specifying USE–TEXT in the frame phrase. This is especially useful for reports.


Copyright © 2004 Progress Software Corporation
www.progress.com
Voice: (781) 280-4000
Fax: (781) 280-4095