bool FileSelector::Execute(bool open, const char *dlgtitle) { ... OPENFILENAME ofn; ... int bufsize = ofn.nMaxFile = (multi ? 32000 : _MAX_PATH); Buffer<char> buffer(bufsize); *(ofn.lpstrFile = buffer) = 0; ... }
computer-programming-forum.com/82-mfc/3079430b194caa71.htm |
"The Open File dialog itself is able to retrieve the complete list of files when selected. However, when processing the list of files, the length of the data processed is limited to 32K bytes due to a limitation in the maximum data buffer allowed to be passed to ExpandEnvironmentStrings. So limit was hit and all the selected files were not open. There is no limit on number of files selected but the limit on the ExpandEnvironmentStrings API. |