//-------------------------------------------------------------------------------------------
// @Author: Aaron Bartell
// @Created:
// @Descr: This is a test
program to illustrate how to call the RCEFN sub procedures. Three
//
graphical files will be created in the '/home/' directory.
// @Notes:
//-------------------------------------------------------------------------------------------
H dftactgrp(*no) bnddir('RCEBND')
/copy qsource,RCECp
//
// Global Definitions
//
D gError ds likeds(RCE_Error) inz
D uid s 15p 0
D dsplyOut s 52a
/free
exsr barChart;
exsr pieChart;
exsr XYChart;
*inlr = *on;
//----------------------------------------------------------------------
// PieChart
//----------------------------------------------------------------------
begsr XYChart;
uid =
RCE_newXYLineChart(
'Quarterly
Sales':
'Axis 1':
'Axis 2':
RCE_PltOrn.vert:
*on: *on: *on:
'/home/xyline123.jpg': 700: 300);
RCE_addXYLineChartData(uid: 1: 5);
RCE_addXYLineChartData(uid: 2: 7);
RCE_addXYLineChartData(uid: 3: 3);
RCE_addXYLineChartData(uid: 4: 5);
RCE_addXYLineChartData(uid: 5: 4);
RCE_addXYLineChartData(uid: 6: 5);
RCE_run(uid: gError);
// Check to see if there was an error that occurred.
if gError.code <> *blanks;
dsplyOut = gError.text;
dsply dsplyOut;
return;
endif;
endsr;
//----------------------------------------------------------------------
// PieChart
//----------------------------------------------------------------------
begsr pieChart;
uid =
RCE_newPieChart(
'Quarterly
Sales':
*on: *on: *on:
'/home/pie123.jpg': 700: 300);
RCE_addPieChartData(uid: 'January': 3100.50);
RCE_addPieChartData(uid: 'February': 5100.50);
RCE_addPieChartData(uid: 'March': 7100.50);
RCE_addPieChartData(uid: 'April': 1100.50);
RCE_run(uid: gError);
// Check to see if there was an error that occurred.
if gError.code <> *blanks;
dsplyOut = gError.text;
dsply dsplyOut;
return;
endif;
endsr;
//----------------------------------------------------------------------
// Barchart
//----------------------------------------------------------------------
begsr barChart;
uid =
RCE_newBarChart(
'Quarterly
Sales':
'Months':
'Dollars':
RCE_PltOrn.vert: *on: *on: *on: '/home/bar123.jpg': 700:
300);
RCE_addBarChartData(uid: 3100.50: 'January Acct 121': 'January');
RCE_addBarChartData(uid: 5100.50: 'February Acct 397': 'February');
RCE_addBarChartData(uid: 7100.50: 'March Acct 573': 'March');
RCE_addBarChartData(uid: 1100.50: 'April Acct 823': 'April');
RCE_run(uid: gError);
// Check to see if there was an error that occurred.
if gError.code <> *blanks;
dsplyOut = gError.text;
dsply dsplyOut;
return;
endif;
endsr;
/end-free