api fileopen dialog - lpstrFile size limitation?
Any reason not to use the MultiSelect parameter of the
Application.GetOpenFilename method?
Anyway, with this:
OpenFile.lpstrFile = String(25000, 0)
I got 156 files (all I selected) into an array:
Dim FileArray as Variant
FileArray = Split(OpenFile.lpstrFile, Chr(0))
--
Jim
"Mike Weaver" wrote in message
...
|I am using Excel to call the win api openfile dialog with the
| OFN_ALLOWMULTISELECT flag set (I am selecting multiple files).
|
| Everything works fine until I select too many files, then my function
| returns nothing:-(
|
| I have tried increasing the size of the string buffer:
| udtStruct.lpstrFile = String(400#, 32)
| which runs, but doesn't increase the number of files I can select.
Nothing
| above about 254 seems to make a difference.
|
| Is this a limitation I am going to have to live with?
|
| Thanks in advance,
| Mike Weaver
|
|
|