[Date Prev][Date Next][Subject Prev][Subject Next][ Date Index][ Subject Index]

Re: LFN max. length in 4DOS?



Hi Carl,

The theoretical maximum length of long filenames (LFN) is 255. But the DOS Program Segment Prefix (PSP) which stores the command line argument has a maximum of 127 characters. This cannot be changed since it is defined this way. However, 4DOS internal commands (DIR, COPY, ECHO, etc) are not affected by this, so the 127-character limitation only applies to the arguments of external commands.

Wengier


On Wednesday, June 15, 2016 7:57 PM, Carl Distefano wrote:


Wengier or anyone familiar with 4DOS, do you know what the maximum
length of a long filename is?

I have been using Wengier's start.exe to open various PDFs with long
filenames. When I tried opening one whose name had 146 characters,
nothing happened. If I give the same command in a CMD.EXE window, the
file opens. I'm assuming that the difference is that the maximum
filename length is shorter in 4DOS than it is in Windows. I tried to
find the answer in the help facility and on various 4DOS sites, but
came up short.

The workaround in a 4DOS batch file, by the way, is to use the SFN
"variable function":

start.exe %@SFN["really long file name"]

--
Carl Distefano
mailto:cld@xxxxxxxx