Navigation: ABC Library Reference > ASCIIFileClass > AsciiFileClass Methods >====== FormatLine (a virtual to format text) ====== | |
FormatLine( line [, line number ] ), PROTECTED, VIRTUAL
FormatLine | A virtual placeholder method to format text. |
line | The label of the STRING variable containing the text to reformat. |
line number | An integer constant, variable, EQUATE or expression that contains the offset or position of the line of text being formatted. If omitted, FormatLine operates on the current line. |
The FormatLine method is a virtual placeholder method to reformat text prior to display at runtime.
Implementation:
The FormatLine method is a placeholder for derived classes. It provides an easy way for you to reformat the text prior to display. The GetLine method calls the FormatLine method.
Example:
INCLUDE('ABASCII.INC') !declare ASCIIViewerClass
MyViewer CLASS(AsciiViewerClass),TYPE !derive MyViewer class
FormatLine PROCEDURE(*STRING),VIRTUAL !prototype virtual FormatLine
END
Viewer MyViewer,THREAD !declare Viewer object
AsciiFile FILE,DRIVER('