Page 1 of 1

How do I check the length of a filename in batch script?

Posted: 2022-Aug-19, 7:58 am
by PiotrMP006
Hi

How do I check the length of a filename in batch script?

Re: How do I check the length of a filename in batch script?

Posted: 2022-Aug-19, 1:17 pm
by Simon Sheppard
Assuming you have the full path/filename, then use Parameter Extensions to split out just the filename, or filename+extension.

Then to get the length use Strlen