/***********************************************************************/ /* Copyright (C) 2002 Definitive Solutions, Inc. All Rights Reserved. */ /* THIS COMPUTER PROGRAM IS PROPRIETARY AND CONFIDENTIAL TO DEFINITIVE */ /* SOLUTIONS, INC. AND ITS LICENSORS AND CONTAINS TRADE SECRETS OF */ /* DEFINITIVE SOLUTIONS, INC. THAT ARE PROVIDED PURSUANT TO A WRITTEN */ /* AGREEMENT CONTAINING RESTRICTIONS ON USE AND DISCLOSURE. ANY USE, */ /* REPRODUCTION, OR TRANSFER EXCEPT AS PROVIDED IN SUCH AGREEMENT */ /* IS STRICTLY PROHIBITED. */ /***********************************************************************/ #if !defined(MYTIPDLGH_B65C3AE1_2ACB_11d6_8ACA_00B0D0529ED2_INCLUDED_) #define MYTIPDLGH_B65C3AE1_2ACB_11d6_8ACA_00B0D0529ED2_INCLUDED_ #pragma once #include "MyTipDlgResource.h" #include "MyDialog.h" #include "MyButton.h" #include "MyStatic.h" ///////////////////////////////////////////////////////////////////////////// // How to add this class to your application. // // Add MyTipDlg.cpp, MyTipDlg.h, MyTipDlgResource.h, MyTipDlg.rc2, and // MyTipDlg.bmp, MyTipDlgNext.ico, and MyTipDlgPrev.ico to your project in the // usual folders. // // You will also need to add the Generic, MyApp, MyLog, MyMenu, MyButton, // MyStatic, and MyHypoerlink classes to your project. // // Add this line to the top of your RC2 file: // #include "MyTipDlgResource.h" // MyTipDlg resources. // // Add this line to the end of your RC2 file: // #include "MyTipDlg.rc2" // MyTipDlg resources. // // Add string table entries for the tips. These *must* start at id number // "nFirstTipOfTheDay" (currently 17000), and be contiguous, because a hole is // interpreted as the end of the tips. The largest tip id number allowed is // 17899, which allows for 900 tips. // // Add a menu item that looks like this, usually in the "Help" menu: // // MENUITEM "Show &Tip of the Day ...", YOUR_ID_HELP_TIP // // To call the dialog, #include this header, and then simply treat it as you // would any other dialog box, passing the Registry key to store its // placement in, and its parent window: // // MyTipDlg dlg(sRegPlacementsKey, AfxGetMainWnd()); // dlg.DoModal(); // ///////////////////////////////////////////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////// // MyTipDlg dialog - "Tip of the Day" // Declare the class depending on this file is in an EXE project or a DLL one. class #ifdef _WINDLL AFX_EXT_CLASS #endif MyTipDlg : public MyDialog { // Construction. public: MyTipDlg(const CString& sRegPlacementsKey, CWnd* pParent = NULL); virtual ~MyTipDlg(); //{{AFX_DATA(MyTipDlg) enum { IDD = IDD_MYTIP }; MyButton m_buttonOK; MyButton m_buttonPrev; MyButton m_buttonNext; BOOL m_bStartup; CString m_sTip; CString m_sTitle; MyStatic m_staticTitle; //}}AFX_DATA //{{AFX_VIRTUAL(MyTipDlg) protected: virtual void DoDataExchange(CDataExchange* pDX); //}}AFX_VIRTUAL // Generated message map functions. protected: //{{AFX_MSG(MyTipDlg) afx_msg void OnNextTip(); afx_msg void OnPrevTip(); afx_msg HBRUSH OnCtlColor(CDC* pDC, CWnd* pWnd, UINT nCtlColor); virtual void OnOK(); virtual BOOL OnInitDialog(); afx_msg void OnPaint(); //}}AFX_MSG DECLARE_MESSAGE_MAP() // Implementation. private: void GetNextTipString(); void GetPrevTipString(); // Data. private: UINT m_uiTipID; // String table id of the current tip. }; //{{AFX_INSERT_LOCATION}} // Microsoft Visual C++ will insert additional declarations immediately before the previous line. #endif // !defined(MYTIPDLGH_B65C3AE1_2ACB_11d6_8ACA_00B0D0529ED2_INCLUDED_)