Pelles C > Feature requests

Optimizer

<< < (3/3)

HellOfMice:
Msdn says:


--- Quote ---lpstrFile

Type: LPTSTR

The file name used to initialize the File Name edit control. The first character of this buffer must be NULL if initialization is not necessary. When the GetOpenFileName or GetSaveFileName function returns successfully, this buffer contains the drive designator, path, file name, and extension of the selected file.
If the OFN_ALLOWMULTISELECT flag is set and the user selects multiple files, the buffer contains the current directory followed by the file names of the selected files. For Explorer-style dialog boxes, the directory and file name strings are NULL separated, with an extra NULL character after the last file name. For old-style dialog boxes, the strings are space separated and the function uses short file names for file names with spaces. You can use the FindFirstFile function to convert between long and short file names. If the user selects only one file, the lpstrFile string does not have a separator between the path and file name.
If the buffer is too small, the function returns FALSE and the CommDlgExtendedError function returns FNERR_BUFFERTOOSMALL. In this case, the first two bytes of the lpstrFile buffer contain the required size, in bytes or characters.
--- End quote ---

https://www.flickr.com/photos/studiodxavier/53247034656/in/pool-nikon_strobist/

John Z:
Thanks HellOfMice!


This is also what frankie schooled me on.  My oversight on setting null to the buffer when I did not needed to initialize it to a specific filename.


John Z

Navigation

[0] Message Index

[*] Previous page

Go to full version