A quick way to use an openfiledialog/savefiledialog. wnd = parent window filter = a C string containing the extensions to look for in filenames when browsing (in MFC format) pathname = buffer where full pathname will be stored of file opened/saved initialdir = what directory to start browsing from. will also contain the new browsing directory if user changed directories. dirlen = max length of in
| 1075 | // user changed directories. |
| 1076 | // dirlen = max length of initialdir buffer including terminating null. |
| 1077 | bool OpenFileDialog(CWnd *wnd, LPCTSTR filter, char *pathname, char *initialdir, int dirlen) { |
| 1078 | return FileDialog(wnd, TRUE, filter, pathname, initialdir, dirlen); |
| 1079 | } |
| 1080 | |
| 1081 | bool SaveFileDialog(CWnd *wnd, LPCTSTR filter, char *pathname, char *initialdir, int dirlen) { |
| 1082 | return FileDialog(wnd, FALSE, filter, pathname, initialdir, dirlen); |
no test coverage detected