Click here to Skip to main content
11,484,162 members (70,827 online)
Click here to Skip to main content
Add your own
alternative version

Bar Graph Control

, 5 Feb 2007 CPOL 49.8K 2K 43
A useful bar graph control, derived from CStatic.
BarGraph_demo.zip
GraphTest_bin
GraphTest.exe
BarGraph_src.zip
GraphTest_src
GraphTest
GraphTest.clw
GraphTest.dsp
GraphTest.dsw
GraphTest.plg
res
GraphTest.ico
// GraphTestDlg.h : header file
//

#if !defined(AFX_GRAPHTESTDLG_H__0924C1FF_BB99_4B6C_92B4_B53B24AC4837__INCLUDED_)
#define AFX_GRAPHTESTDLG_H__0924C1FF_BB99_4B6C_92B4_B53B24AC4837__INCLUDED_

#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000

#include "GraphCtrl.h"
#include "mystatic.h"
#include "afxwin.h"
/////////////////////////////////////////////////////////////////////////////
// CGraphTestDlg dialog

class CGraphTestDlg : public CDialog
{
// Construction
public:
	CGraphTestDlg(CWnd* pParent = NULL);	// standard constructor

// Dialog Data
	//{{AFX_DATA(CGraphTestDlg)
	enum { IDD = IDD_GRAPHTEST_DIALOG };
	CGraphCtrl	m_Graph;
	int		m_Scale;
	BOOL	m_Simulate;
	//}}AFX_DATA

	// ClassWizard generated virtual function overrides
	//{{AFX_VIRTUAL(CGraphTestDlg)
	protected:
	virtual void DoDataExchange(CDataExchange* pDX);	// DDX/DDV support
	//}}AFX_VIRTUAL

// Implementation
protected:
	HICON m_hIcon;

	// Generated message map functions
	//{{AFX_MSG(CGraphTestDlg)
	virtual BOOL OnInitDialog();
	afx_msg void OnSysCommand(UINT nID, LPARAM lParam);
	afx_msg void OnPaint();
	afx_msg HCURSOR OnQueryDragIcon();
	afx_msg void OnSelchangeScaleCombo();
	afx_msg void OnTimer(UINT nIDEvent);
	afx_msg void OnCheckSimu();
	//}}AFX_MSG
	DECLARE_MESSAGE_MAP()
public:
	int m_iYScale;
	afx_msg void OnBnClickedSetScale();
	afx_msg void OnBnClickedMoveUp();
	afx_msg void OnBnClickedMoveDown();
	afx_msg void OnEnChangeScale();
	INT m_DispFrom;
	INT m_DispTo;
	CMyStatic m_BGStat;
	CMyStatic m_AxsStat;
	CMyStatic m_TxtStat;
	afx_msg void OnBnClickedTxtcolor3();
	afx_msg void OnBnClickedAxcolor2();
	afx_msg void OnBnClickedBgcolor();
	afx_msg void OnCbnSelchangeComboBar();
	CMyStatic m_BarStat;
	CComboBox m_BarCombo;
	afx_msg void OnBnClickedBarcolor();
};

//{{AFX_INSERT_LOCATION}}
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.

#endif // !defined(AFX_GRAPHTESTDLG_H__0924C1FF_BB99_4B6C_92B4_B53B24AC4837__INCLUDED_)

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

Share

About the Author

Shaibujan
Team Leader
India India
Mr. Shaibujan has got 9+ yrs of programming experience in C/C++, on various domains like Cryptography, Biometric Security, Network Security, Pattern Recognition, Image Processing, MPEG2, MPEG4, H.264, AAC etc.

| Advertise | Privacy | Terms of Use | Mobile
Web04 | 2.8.150520.1 | Last Updated 6 Feb 2007
Article Copyright 2007 by Shaibujan
Everything else Copyright © CodeProject, 1999-2015
Layout: fixed | fluid