|Contents:||Main||Chapter||See Also:||Getting Started Manual||Advanced User Manual|
Call ^DIWP to format and (optionally) output any group of text lines.
Before calling ^DIWP, you should kill the global ^UTILITY($J,"W").
^DIWP works in two modes (based on whether the DIWF input parameter contains "W" or not):
The string of text to be added as input to the formatter.
The X input string may contain |-windows, as described in the "Formatting Text with Word Processing Windows" topic in the "Advanced Edit Techniques" chapter of the "VA FileMan Advanced User Manual" (e.g., |SETTAB(9,23,44)|). The expressions within the windows will be processed as long as they are not context-dependent; that is, as long as they do not refer symbolically to database field names. Thus, |TODAY| will cause today's date to be inserted into the formatted text, but |SSN| will be printed out as it stands, because it cannot be interpreted in context.
The (integer-valued) left margin for the text. Set this to a postive number, 1 or greater. Do not change the value of DIWL if you are making repeated calls to ^DIWP to format text.
The (integer-valued) right margin for the text.
A string of format control parameters. If contained in DIWF, the parameters have the following effects:
When making repeated calls to ^DIWP, don't mix modes. Use "write" or "accumulate" mode, but don't switch between them.
|Cn||The text will be formatted in a column width of n, thus overriding the value of DIWR.|
|D||The text will be in double-spaced format.|
|In||The text will be indented n columns in from the left margin (DIWL).|
|N||Each line will be printed as it appears in the text (no-wrap). If DIWF contains N, the value of DIWR will be ignored. See the "Advanced Edit Techniques" chapter in the "VA FileMan Advanced User Manual" for details about word wrapping.|
|R||The text will be in right-justified format.|
||||Word processing windows (material within vertical bars) will not be evaluated. The window will print as it exists in the word processing field.|
Reviewed/Updated: March 10, 2007