RPC HELP BROKER RTRNFMT XWBLIB

From VistApedia
Revision as of 01:16, 6 July 2015 by Kdtop (talk | contribs) (Created page with " RPC Broker Help Home <h2>$$RTRNFMT^XWBLIB</h2> Use this function in the M code called by an RPC to change the return value type that the RPC will return o...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

RPC Broker Help Home

$$RTRNFMT^XWBLIB

Use this function in the M code called by an RPC to change the return value type that the RPC will return on the fly.

Format

   $$RTRNFMT^XWBLIB(type, wrap)

Input

  • type: Set this to the RETURN VALUE TYPE to change the RPC's setting to. You can set it to one of the following numeric or free text values:
    • numeric -- free text
    • 1 -- SINGLE VALUE
    • 2 -- ARRAY
    • 3 -- WORD PROCESSING
    • 4 -- GLOBAL ARRAY
    • 5 -- FOR GLOBAL INSTANCE
  • wrap: Set to 1 to set the RPC's WORD WRAP ON setting to True; set to 0 to set the RPC's WORD WRAP ON setting to False.

Output

Return Value 0 if the return value type could not be changed; otherwise, the numeric code representing the return value type that the RPC is changed to.

Example

   IF '$$RTRNFMT^XWBLIB("ARRAY",1) DO
   . ; branch to code if can't change RPC type