read filenames of directory
Hello to all forms developers !
I have a problem with Forms 6i (client/server). I want the user to select multiple files from a directory. I know this can be done using the OpenFileEx function of the d2kwutil library. But this function only returns a string which max. length is 4096 characters. This restricts the number of selectable files. So I tried another way : I used the HOST built-in to generate a file containing all filenames, like this :
host('dir /b > files.txt', no_screen) and then read out the filenames with routines of text_io package.
The parameter /b for the dir command lists only the filenames.
But to my surprise filenames longer than 8 characters are shortened to only 8 characters so that these filenames cannot be used by other routines.
Did anyone else face and solve this problem and share his experience with me ?
Regards
Kai