My IPeople

Community discussion for IPeople products and services
Welcome to My IPeople Sign in | Help
in
Home Blogs Forums

Use NPR Report to write to the Windows Clipboard (MAGIC)

Last post 08-04-2007, 12:08 PM by Brian. 0 replies.
Sort Posts: Previous Next
  •  08-04-2007, 12:08 PM 503

    Use NPR Report to write to the Windows Clipboard (MAGIC)

    You can modify your report so that everything that prints is sent to your Windows clipboard.  This is of course only possible
    for reports run on the Meditech Remote Workstation.  Also, it is not possible for reports printed to a Spool file.

    The Meditech Remote Workstation responds to the D(30)_"CB" by storing all subsequent data sent the Workstation in the
    Windows clipboard.  The D(0) command instructs the Workstation to stop storing data in the Windows clipboard.

    D is called the Decode function in the Meditech programming language.  It creates the ASCII character associated with the
    code provided in parentheses. 

    Here are the steps:

    Step 1: Add the following Footnotes: AL START "DPM.zcus.report.M.print"^/R.TRANS
                                                          AL CLOSE.UP close.up

    Step 2: Replace 'DPM' with the your Report DPM and 'report' with the name of your report.

    Step 3: File and translate your report.

    Step 4: Create a macro called 'close.up' with the following code, then file and translate it:

     IF{@Not(@.pc);
        @Z.spool;
        @Not(+/TEXT[""]);
        /R.HALTED;
        @Not(@Z.rpt.found);
        D(30)_"CB"^#,
        ""^TEMP,
        DO{+/TEXT[TEMP]^TEMP /TEXT[TEMP]_@Z.cr.lf^#,
                                              ""^/TEXT[TEMP]},
        D(0)^#}

    Step 5: Create a macro called 'print' with the following code, then file and translate it:

     /R.OUT:0X^/TEXT[-/TEXT[""]+1],
     /R.OUT^!;

    Step 6: Retranslate your report.

View as RSS news feed in XML
Powered by Community Server, by Telligent Systems