Introduction
This control class CPieChartCtrl
is derived from CWnd
. The purpose is to create a
simple 2D pie chart in a dialog. The code is created and compiled with Visual C++ 5.0 SP3
under Windows 98.
How to use
- Use the MS Visual C++ dialog editor to place a custom control on the dialog, and
enter "
PIE_CHART_CTRL
" as the Class name.
- Add a
CPieChartCtrl
class member in the header file
#include "PieChartCtrl.h"
...
CPieChartCtrl m_wndChart;
- Subclass the class member with the control in
InitDialog()
m_wndChart.SubclassDlgItem(IDC_PIECHART1, this);
- Use these functions to edit to chart
m_wndChart.SetTitle("Chart Title");
m_wndChart.Reset();
m_wndChart.AddPiece(colorBack, colorText, nAngle, strInfo);
This article has no explicit license attached to it but may contain usage terms in the article text or the download files themselves. If in doubt please contact the author via the discussion board below.
A list of licenses authors might use can be found here
This member has not yet provided a Biography. Assume it's interesting and varied, and probably something to do with programming.