What is the use of DDV and DDX routines ?
Answers were Sorted based on User's Feedback
Answer / zerozero
DDX-Transfer the data b/w dialog control and data member.
ex: DDX_TEXT(pDX,IDC_NAME,m_strName)
DDV: Validated the data entered into dialog control varibles.
Ex: DDX_TEXT(pDX,IDC_NAME,m_strName)
DDV_TEXT(pDX,m_strName,30)
| Is This Answer Correct ? | 8 Yes | 0 No |
Answer / arundeva
DDX(DoDataExchange()
Is use To associate Control variable To Control ID.
DDV(DoDataValidation)
Is used to Set the range of control Value.
| Is This Answer Correct ? | 4 Yes | 0 No |
Answer / dharani
1)dialog data exchange (DDX)
All dialog data functions are done with C++ code. There are
no special resources or magic macros. The heart of the
mechanism is a virtual function that is overridden in every
dialog class that does dialog data exchange and validation.
It is always found in this form:
Copy Code
void CMyDialog::DoDataExchange(CDataExchange* pDX)
{
CDialog::DoDataExchange(pDX); // call base class
//{{AFX_DATA_MAP(CMyDialog)
<data_exchange_function_call>
<data_validation_function_call>
//}}AFX_DATA_MAP
}
2)dialog data validation (DDV)
| Is This Answer Correct ? | 1 Yes | 0 No |
Answer / prabhu.somasundaram
DDV - > Associate Single control with single variable.So
that we can define the properties for that associated variable.
DDX - > Associate Input Validation Function with Particular
variable.
for ex:
void DDV_Check(CDataExchange* dx, int DividerValue)
{
if ( DividerValue< 0)
{
AfxMessageBox("Not Valid Input for Divider");
dx->Fail();
}
}
///Calling Function
//{{AFX_DATA_MAP(CDlg)
DDV_Check(dx, m_age); // Our function
//}}AFX_DATA_MAP
| Is This Answer Correct ? | 2 Yes | 3 No |
What is the file extension used for C++ class implementation files?
How do I uninstall and reinstall microsoft visual c++ runtime libraries?
What is visual c++ used for?
What is microsoft visual c++ 2008 redistributable?
How do I fix microsoft visual c++ 2015 setup failed?
What is type-safety?
What is a copy constructor? What is the need for it?
Explain pointer to the constant and constant pointer? Explain difference between them.
What is the difference between an MLE and an SLE?
Explain the significance of initapplication() in vc++.
What are the advantages of a message map
hello sir i need movie editing and mixing software .where it is available and what is the site address