Google Search - Blog...........

ABAP - Report Program On Graphs.

REPORT ZGRAPH_TEST.

DATA: BEGIN OF TAB OCCURS 5,
CLASS(5) TYPE C,
VAL1 TYPE I,
VAL2 TYPE I,
VAL3 TYPE I,
END OF TAB.

DATA: BEGIN OF OPTTAB OCCURS 1,
C(20),
END OF OPTTAB.

MOVE: 'fan' TO TAB-CLASS,
12 TO TAB-VAL1,
8 TO TAB-VAL2,
15 TO TAB-VAL3.
APPEND TAB.
CLEAR TAB.

MOVE: 'cool' TO TAB-CLASS,
15 TO TAB-VAL1,
10 TO TAB-VAL2,
18 TO TAB-VAL3.
APPEND TAB.
CLEAR TAB.

MOVE: 'DA' TO TAB-CLASS,
17 TO TAB-VAL1,
11 TO TAB-VAL2,
20 TO TAB-VAL3.
APPEND TAB.
CLEAR TAB.

OPTTAB = 'FIFRST = 3D'.
APPEND OPTTAB. "// Grafik-Typ

OPTTAB = 'P3TYPE = TO'.
APPEND OPTTAB. "// Objektart

OPTTAB = 'P3CTYP = RO'.
APPEND OPTTAB. "// Farben der Objekte

OPTTAB = 'TISIZE = 2'.
APPEND OPTTAB. "// Haupttitelgröße

OPTTAB = 'CLBACK = X'.
APPEND OPTTAB. "// Background Color

CALL FUNCTION 'GRAPH_MATRIX_3D'
EXPORTING
COL1 = '1997'
COL2 = '1998'
COL3 = '1999'
DIM2 = 'Products'
DIM1 = 'Years'
TITL = 'Sales In Rs. Crores'
TABLES
DATA = TAB
OPTS = OPTTAB
EXCEPTIONS
OTHERS = 1.

LEAVE PROGRAM.

No comments:

Post a Comment