Click here to Skip to main content
15,921,113 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: How can I know where a program leaks memory if it hangs after 48 hours of working? Pin
BlackDice22-Nov-04 8:46
BlackDice22-Nov-04 8:46 
AnswerRe: How can I know where a program leaks memory if it hangs after 48 hours of working? Pin
floresa922-Nov-04 11:54
floresa922-Nov-04 11:54 
Generalslider Pin
teneff22-Nov-04 4:42
teneff22-Nov-04 4:42 
GeneralRe: slider Pin
David Crow22-Nov-04 4:51
David Crow22-Nov-04 4:51 
GeneralRe: slider Pin
teneff22-Nov-04 5:18
teneff22-Nov-04 5:18 
GeneralRe: slider Pin
David Crow22-Nov-04 6:12
David Crow22-Nov-04 6:12 
GeneralWinprog OPENFILENAME Pin
henry12822-Nov-04 3:22
henry12822-Nov-04 3:22 
GeneralRe: Winprog OPENFILENAME Pin
David Crow22-Nov-04 5:12
David Crow22-Nov-04 5:12 
henry128 wrote:
However,this seems not to be the case when the multiselect flag is set. It seems that in multi-mode directory information is no longer preserved. Sadly msdn doesn't touch this subject, does anyone know if ,and how the path info in case of multiselect is stored?

This works for me:

OPENFILENAME ofn = {0};
char szBuffer[4096] = {0},
     szPath[MAX_PATH];
 
ofn.lStructSize = sizeof(OPENFILENAME);
ofn.lpstrFilter = "All Files (*.*)\0*.*\0";
ofn.lpstrFile   = szBuffer;
ofn.nMaxFile    = sizeof(szBuffer);
ofn.Flags       = OFN_ALLOWMULTISELECT | OFN_EXPLORER;
 
if (GetOpenFileName(&ofn) != FALSE)
{
    lstrcpy(szPath, ofn.lpstrFile);
    ofn.lpstrFile += ofn.nFileOffset;
 
    while (*(ofn.lpstrFile) != '\0')
    {
        TRACE("%s\\%s\n", szPath, ofn.lpstrFile);
        ofn.lpstrFile += lstrlen(ofn.lpstrFile) + 1;
    }
}
However, without a code snippet showing what you have (tried), it's hard to suggest a solution.


"Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow


QuestionHow to get Security Options found in MMC Pin
Yuvaraj N22-Nov-04 2:30
Yuvaraj N22-Nov-04 2:30 
Generalsmtp in mail Pin
Member 150757022-Nov-04 1:30
Member 150757022-Nov-04 1:30 
GeneralRe: smtp in mail Pin
David Crow22-Nov-04 3:16
David Crow22-Nov-04 3:16 
GeneralRe: smtp in mail Pin
BaldwinMartin23-Nov-04 10:11
BaldwinMartin23-Nov-04 10:11 
GeneralSaving a file Pin
efendy22-Nov-04 1:30
efendy22-Nov-04 1:30 
GeneralRe: Saving a file Pin
David Crow22-Nov-04 8:52
David Crow22-Nov-04 8:52 
QuestionHow to do this? Pin
pubududilena22-Nov-04 0:37
pubududilena22-Nov-04 0:37 
AnswerRe: How to do this? Pin
Steve S22-Nov-04 1:27
Steve S22-Nov-04 1:27 
GeneralGetting User Details Pin
Yuvaraj N22-Nov-04 0:23
Yuvaraj N22-Nov-04 0:23 
GeneralRe: Getting User Details Pin
ThatsAlok22-Nov-04 17:24
ThatsAlok22-Nov-04 17:24 
GeneralLinker Error In SAL module on linking open office code Pin
nitinmahajan8022-Nov-04 0:22
nitinmahajan8022-Nov-04 0:22 
GeneralTTN_NEEDTEXT Not Calling Pin
Rajesh_Parameswaran22-Nov-04 0:16
Rajesh_Parameswaran22-Nov-04 0:16 
GeneralRe: TTN_NEEDTEXT Not Calling Pin
David Crow22-Nov-04 8:38
David Crow22-Nov-04 8:38 
GeneralRe: TTN_NEEDTEXT Not Calling Pin
Rajesh_Parameswaran22-Nov-04 18:57
Rajesh_Parameswaran22-Nov-04 18:57 
QuestionHow to send a message to a dialog Pin
Nest22-Nov-04 0:15
Nest22-Nov-04 0:15 
AnswerRe: How to send a message to a dialog Pin
Rajesh_Parameswaran22-Nov-04 0:47
Rajesh_Parameswaran22-Nov-04 0:47 
GeneralRe: How to send a message to a dialog Pin
Nest22-Nov-04 0:55
Nest22-Nov-04 0:55 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.