dtestdlmy.cpp
Upload User: chennaikun
Upload Date: 2022-05-07
Package Size: 2328k
Code Size: 2k
Category:

Dialog_Window

Development Platform:

Visual C++

  1. // dtestdlmy.cpp : implementation file
  2. //
  3. #include "stdafx.h"
  4. #include "testdl.h"
  5. #include "dtestdlmy.h"
  6. #ifdef _DEBUG
  7. #define new DEBUG_NEW
  8. #undef THIS_FILE
  9. static char THIS_FILE[] = __FILE__;
  10. #endif
  11. /////////////////////////////////////////////////////////////////////////////
  12. // CDtestdlmy dialog
  13. CDtestdlmy::CDtestdlmy(CWnd* pParent /*=NULL*/)
  14. : CDialog(CDtestdlmy::IDD, pParent)
  15. {
  16. //{{AFX_DATA_INIT(CDtestdlmy)
  17. m_fpcs = 0.0f;
  18. m_fpcv = 0.0f;
  19. m_fph = 0.0f;
  20. //}}AFX_DATA_INIT
  21. ASSERT(pParent);
  22. m_pParent=pParent;
  23. }
  24. void CDtestdlmy::DoDataExchange(CDataExchange* pDX)
  25. {
  26. CDialog::DoDataExchange(pDX);
  27. //{{AFX_DATA_MAP(CDtestdlmy)
  28. DDX_Text(pDX, IDC_FV_PCS, m_fpcs);
  29. DDX_Text(pDX, IDC_FV_PCV, m_fpcv);
  30. DDX_Text(pDX, IDC_FV_PH, m_fph);
  31. //}}AFX_DATA_MAP
  32. }
  33. BEGIN_MESSAGE_MAP(CDtestdlmy, CDialog)
  34. //{{AFX_MSG_MAP(CDtestdlmy)
  35. ON_BN_CLICKED(ID_FV_POK, OnFvPok)
  36. ON_BN_CLICKED(IDC_FV_WJX, OnFvWjx)
  37. ON_BN_CLICKED(IDC_FV_WZJ, OnFvWzj)
  38. //}}AFX_MSG_MAP
  39. END_MESSAGE_MAP()
  40. /////////////////////////////////////////////////////////////////////////////
  41. // CDtestdlmy message handlers
  42. void CDtestdlmy::OnFvPok() 
  43. {
  44. // TODO: Add your control notification handler code here
  45.    float FV_i;
  46.    FV_i=1;
  47.    UpdateData(true);
  48.    m_pParent->SendMessage(WM_DLG_CREATE,(WPARAM)FV_i);
  49. }
  50. void CDtestdlmy::OnFvWjx() 
  51. {
  52. // TODO: Add your control notification handler code here
  53.    float FV_i;
  54.    FV_i=3;
  55.    m_pParent->SendMessage(WM_DLG_CREATE,(WPARAM)FV_i);
  56. }
  57. void CDtestdlmy::OnFvWzj() 
  58. {
  59. // TODO: Add your control notification handler code here
  60.    float FV_i;
  61.    FV_i=2;
  62.    m_pParent->SendMessage(WM_DLG_CREATE,(WPARAM)FV_i);
  63. }