home *** CD-ROM | disk | FTP | other *** search
/ io Programmo 23 / IOPROG_23.ISO / SOFT / NUMEDIT.ZIP / NumEdit.h < prev    next >
Encoding:
C/C++ Source or Header  |  1999-01-05  |  1.5 KB  |  60 lines

  1. #if !defined(AFX_NUMEDIT_H__7482F7FF_A479_11D2_A6A7_00600844997A__INCLUDED_)
  2. #define AFX_NUMEDIT_H__7482F7FF_A479_11D2_A6A7_00600844997A__INCLUDED_
  3.  
  4. #if _MSC_VER >= 1000
  5. #pragma once
  6. #endif // _MSC_VER >= 1000
  7. // NumEdit.h : header file
  8. //
  9.  
  10. /////////////////////////////////////////////////////////////////////////////
  11. // CNumEdit window
  12.  
  13. class CNumEdit : public CEdit
  14. {
  15. // Construction
  16. public:
  17.     CNumEdit();
  18.  
  19. // Attributes
  20. public:
  21.     enum {VALID = 0x00, OUT_OF_RANGE = 0x01, INVALID_CHAR = 0x02};
  22. // Operations
  23. public:
  24.  
  25. // Overrides
  26.     // ClassWizard generated virtual function overrides
  27.     //{{AFX_VIRTUAL(CNumEdit)
  28.     //}}AFX_VIRTUAL
  29.  
  30. // Implementation
  31. public:
  32.     virtual void GetRange(float &max, float &min);
  33.     virtual void SetRange(float max, float min);
  34.     virtual void Verbose(BOOL v);
  35.     virtual BOOL Verbose();
  36.     virtual int IsValid();
  37.     virtual int IsValid(const CString &str);
  38.  
  39.     virtual void SetValue(float val);
  40.     virtual float GetValue();
  41.     virtual ~CNumEdit();
  42.  
  43.     // Generated message map functions
  44. protected:
  45.     BOOL m_Verbose;
  46.     float m_Delta, m_MinValue, m_MaxValue;
  47.     //{{AFX_MSG(CNumEdit)
  48.     afx_msg void OnChar(UINT nChar, UINT nRepCnt, UINT nFlags);
  49.     //}}AFX_MSG
  50.  
  51.     DECLARE_MESSAGE_MAP()
  52. };
  53.  
  54. /////////////////////////////////////////////////////////////////////////////
  55.  
  56. //{{AFX_INSERT_LOCATION}}
  57. // Microsoft Developer Studio will insert additional declarations immediately before the previous line.
  58.  
  59. #endif // !defined(AFX_NUMEDIT_H__7482F7FF_A479_11D2_A6A7_00600844997A__INCLUDED_)
  60.