File Operations
For example: UpdateData(TRUE); CFileDialog dlg(1,NULL,NULL,OFN_HIDEREADONLY ,"All Files(*.*)|*.*||"); if(IDOK!=dlg.DoModal())return; m_filename=dlg.GetPathName(); UpdateData(FALSE); When user click browse button, the function UpdateData(TRUE) will refresh the value from controls to variables. As the same reason, the function UpdateData(FALSE) will refresh the value from variables to controls. #How to open a file with a dialog? The code CFileDialog dlg(1,NULL,NULL,OFN_HIDEREADONLY ,"All Files(*.*)|*.*||"); is supposed to open any files. The following hyperlink contains how to use the