NTEPB
Member
Hi everyone! I know it's been a LONG time since I've posted on this forum. I do have an interesting DOS question, however. Maybe some of you could help me out.
I'm working on a DOS batch file to archive my dad's old 5.25" floppy diskettes. The computers that will be reading the diskettes range from IBM 5150s (with 360KB drives) to Pentium-class machines (with 1.2MB drives). The machines will be running PC-DOS 3.30 to MS-DOS 7.x (from Win9x), depending on the CPU architecture.
What I'm needing to do is this: while running my batch file, I need the computer to determine if there are any files on each diskette with hidden or system attributes. If the computer does find hidden or system files, I need an ERRORLEVEL flag set so I can branch to another section of the batch file and run another command.
Obviously, DOS 3.30 can't use the DIR /A:HS command, and DIR (on any DOS version) will not generate an ERRORLEVEL code at all, due to DIR being an internal DOS command. I looked high and low on Google, and I did find 2 old DOS utilities (DH.EXE and FINDHID.EXE); however, those utilities don't generate ERRORLEVEL codes at all.
Does anyone know of a utility (or some batch-file workaround) that might work for my needs? Please keep in mind that this needs to work using DOS 3.30 and later.
Thanks in advance!
Jon
I'm working on a DOS batch file to archive my dad's old 5.25" floppy diskettes. The computers that will be reading the diskettes range from IBM 5150s (with 360KB drives) to Pentium-class machines (with 1.2MB drives). The machines will be running PC-DOS 3.30 to MS-DOS 7.x (from Win9x), depending on the CPU architecture.
What I'm needing to do is this: while running my batch file, I need the computer to determine if there are any files on each diskette with hidden or system attributes. If the computer does find hidden or system files, I need an ERRORLEVEL flag set so I can branch to another section of the batch file and run another command.
Obviously, DOS 3.30 can't use the DIR /A:HS command, and DIR (on any DOS version) will not generate an ERRORLEVEL code at all, due to DIR being an internal DOS command. I looked high and low on Google, and I did find 2 old DOS utilities (DH.EXE and FINDHID.EXE); however, those utilities don't generate ERRORLEVEL codes at all.
Does anyone know of a utility (or some batch-file workaround) that might work for my needs? Please keep in mind that this needs to work using DOS 3.30 and later.
Thanks in advance!
Jon