PC SOFT

ONLINE HELP
FOR WINDEV, WEBDEV AND WINDEV MOBILE

Home | Sign in | English US

WINDEV
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadApple WatchUniversal Windows 10 AppWindows Mobile
Others
Stored procedures
Indicates the type of category in a Waterfall chart.
Versions 21 and later
Universal Windows 10 App This function is now available in Universal Windows 10 App mode.
New in version 21
Universal Windows 10 App This function is now available in Universal Windows 10 App mode.
Universal Windows 10 App This function is now available in Universal Windows 10 App mode.
Versions 23 and later
PHP This function is now available for the PHP sites.
New in version 23
PHP This function is now available for the PHP sites.
PHP This function is now available for the PHP sites.
Example
// TO for 2011
grAddData(CHART_Waterfall, 1, 1, 298000)
grCategoryLabel(CHART_Waterfall, 1, "TO 2011")

// Add the profits
grAddData(CHART_Waterfall, 1, 2, 420000)
grCategoryLabel(CHART_Waterfall, 2, "Profits" + CR + "products")
grAddData(CHART_Waterfall, 1, 3, 210000)
grCategoryLabel(CHART_Waterfall, 3, "Profits" + CR + "services")

// Costs
grAddData(CHART_Waterfall, 1, 4, -170000)
grCategoryLabel(CHART_Waterfall, 4, "Fixed costs")
grAddData(CHART_Waterfall, 1, 5 -140000)
grCategoryLabel(CHART_Waterfall, 5, "Variable costs")

// TO for 2012
grAddData(CHART_Waterfall, 1, 6, 0)
grCategoryLabel(CHART_Waterfall, 6, "TO 2012")
grWaterfallCategoryType(CHART_Waterfall, 6, grSubTotal)

// Cumulated TO
grAddData(CHART_Waterfall, 1, 7, 0)
grCategoryLabel(CHART_Waterfall, 7, "Cumulated TO")
grWaterfallCategoryType(CHART_Waterfall, 7, grTotal)
Syntax
grWaterfallCategoryType(<Chart Name> , <Category> , <Type of Category>)
<Chart Name>: Character string (with or without quotes)
Name of chart to use. This name corresponds to:
  • the chart name defined by programming with grCreate.
  • the name of the Chart control found in the window editor, report editor or page editor.
PHP Only the interactive Chart controls are available.
<Category>: Integer
Number of the category to use.
<Type of Category>: Integer constant
Type of Category:
grDefaultPositive or negative values of the chart.
grSubTotalSub-total values.
If the category corresponds to a sub-total, the value stored for this category is ignored. For this category, the Waterfall chart displays a bar corresponding to the sum of all previous categories from the last total or sub-total.
grTotalTotal values.
If the category corresponds to a total, the value stored for this category is ignored. For this category, the Waterfall chart displays a bar corresponding to the sum of all previous categories from the beginning of the chart.
Remarks
  • Special case: the first category
    The first category is always a "total" category but the specified value is displayed: it is the start value.
  • This function applies to the Waterfall charts only.
Related Examples:
WD Chart Training (WINDEV): WD Chart
[ + ] This educational example present different uses of the chart control.
The following charts are presented:
- Semi-circular
- Donut
- Pie
- Sunburst
- Line
- Scatter
- 3D Scatter
- Column
- Area
- Bubble
- Radar
- Funnel
- Surface
- Waterfall
- Composite

The main features presented in this example are the ability to customize the charts by programming as well as the method used to fill a chart from a HFSQL file or in the editor.
Components
WINDEVWEBDEV - Server codeReports and Queries wd230grf.dll
Windows Mobile wp230grf.dll
Linux wd230grf.so
Minimum required version
  • Version 19
This page is also available for…
Comments
Click [Add] to post a comment