Long filenames

Windows 3.x and all 16-bit programs follow the 8.3 filename convention. Windows 95 and all 32-bit programs use filenames of up to 255 characters. They can include spaces and other characters that were never used in 8.3 filenames. This can cause problems depending on what your program does with filenames. If your interaction with filenames doesn’t involve manipulating those filenames, you shouldn’t have too many problems. If, on the other hand, you do manipulate those filenames, watch out for the following assumptions, all true with 8.3 filenames and now all false.

Any code that makes any of these assumptions is likely to run into trouble when running under 32-bit Visual Basic 4 or Visual Basic 5.

One solution is to write an ActiveX server to convert all dialog boxes to 8.3 internally but display long filenames to the users. Your 8.3 filename code can then run unmodified. Another option is to use the Win32 functions GetFullPathName and GetShortPathName to convert your filenames as required. A third option is to rewrite the code.