Key Concepts

Chart routines act on the current chart, dataset, or text object. Create or select the object first, then apply its settings.

Description:

Choose the current object

.CHART INITIALIZE makes the new chart current. Adding a label makes that label current, so the next font or color call applies to it. .CHART RENDER renders the current chart with its associated data.

Leave names blank when one chart and one dataset are enough. Give objects distinct names when you need to switch between them. Use .CHART SET CURRENT to return to a named chart or .DATASET SET CURRENT to resume adding points to a named dataset. Other objects, including shapes, can also be named.

Pass arguments and check the result

  1. Open the routine reference and issue the PASS statements in the order shown. Omitting a required argument causes a CANCEL that identifies the missing parameter.
  2. To supply a later optional argument, pass a placeholder for each unused position before it. For example, to supply only the second optional argument, pass a blank field in the first position if the routine accepts a blank there. Token values such as TOPLEFT are case insensitive.
  3. After the call, check the 0CD work field with the same name as the routine. A nonblank result identifies an error. Use SCAN on the field in the ILF editor to see its result tokens.

Choose a call and an example

Use the documented dot-prefixed routines in 0CD. Other routines there support the chart implementation. The 1CD example application includes charts based on the ChartDirector samples. The pie chart walkthrough shows a small example with data, labels, and a rendered image.

The wiki examples can be copied into the ILF editor. GOSUB includes the called code in the executable module. Calling a large routine such as .CHART RENDER with SUBR and SUBPROCESS reduces the caller’s compile time and module size, with a small invocation cost on each call.

Comments

Read what other users have said about this page or add your own comments.


 

-- JeanNeron - 2011-09-15
Topic revision: r12 - 03 Dec 2026, AdminUser - This page was cached on 03 Dec 2026 - 20:15.

Powered by Foswiki. Wiki content belongs to its contributing authors.