Home > Back-end >  CDM_GETFILEPATH messages sent to CFileDialog window for the string is empty?
CDM_GETFILEPATH messages sent to CFileDialog window for the string is empty?

Time:10-26

Thanks for your big browse
I don't use the hook technology, simple has built a CDM_GETFILEPATH messages sent to another engineering CFileDialog window, get the string length & gt; 0, but why get string is empty? (I have selected file, the file path different ret value, there is no "open" button)

//code
HWND FileDialog=FindWindow (NULL, "open");
Int ret=SendMessage (FileDialog CDM_GETFILEPATH, NULL, NULL);
If (ret)
{
Char File [1024].
SendMessage (FileDialog CDM_GETFILEPATH, 1024, (LPARAM) File).
Printf (" FilePath=% s ", the File).
}
  • Related