Home
  Add-Ons for
SAP® systems
  CT-Assist_Module
  Software Assistants
  User comments
  Costs/benefit analysis
  R/3® Integration
  PDF / Download
  CT-Debug & Trace_Module
  R/3® Integration
  PDF / Download
  CT-Codeview & Analyzer
  CT-Test & Optimizer
  eLearning for ABAP™
  CT-Professsional_100+Help
  CT-Professsional_100
  CT-Understanding_100
  CT-Help_Workbench
  ABAP™ Programs
  Shop [SSL]
  Downloads
 


Home > ABAP™-Programs > Y9030023

ABAP™-Programs

Report Y9030023

This reports shows how to create any report on every target system reachable via RFC.

[for Download or 'cut and paste']


REPORT Y9030023 LINE-SIZE 50.
*
**********************         HEADER                    **************
*
* Copyright (c) 1999 by Stefan riedel-Seifert,
*               78034 Boeblingen, http://www.hp.com
*
*     You can use or modify this report for your own work as long
*               as you don't try to sell or republish it.
*      In no event will the author be liable for indirect, special,
*        Incidental, or consequental damages (if any) arising out of
*                       the use of this report.
*//////////////////////////////////////////////////////////////////////*
* Parameters.
  parameters:
    PR_DEST LIKE RFCDES-RFCDEST DEFAULT 'ABXR2_XR2_00'.

* Data.
  data:
    lv_errormessage like sy-msgv1,
    gt_program      like progtab   occurs 0 with header line,
    gt_writes       like listzeile occurs 0 with header line.

* Start of selection.
  start-of-selection.

* Init.
  clear:
    gt_program, gt_program[],
    gt_writes,  gt_writes[].

* Fill.
  gt_program = 'Report <>.'.
  append gt_program.
  clear  gt_program.
  GT_PROGRAM = 'Write /1 ''Hello world''.'.
  append gt_program.
  clear  gt_program.
*............................................ add from CT-Team .........
  APPEND 'WRITE: /1 ''SY-REPID:'', SY-REPID.' TO GT_PROGRAM.
  CLEAR GT_PROGRAM.
*.......................................................................
*
* Create on target system and retrieve screen output.
  call function 'RFC_ABAP_INSTALL_AND_RUN'
       destination         pr_dest
       importing
            errormessage = lv_errormessage
       tables
            program      = gt_program
            writes       = gt_writes
       exceptions
            others       = 1.
*
*............................................ add from CT-Team .........
  LOOP AT GT_WRITES.
    WRITE: /1 GT_WRITES.
  ENDLOOP.
*
************************************************************************
******************** end of program ************************************
************************************************************************