On Thu, 31 Jan 2002, Ben A L Jemmett wrote: > > dir %1.*/s/p/b > > " > > and call it "FINDIT.BAT". > > > > This should work for any version of DOS 3.30 or higher, and quite possibly > > earlier. > > DIR /S and /B were introduced with MS-DOS 5, I believe. 3.2 and 3.3 > certainly didn't support that -- you had to do ATTRIB /S.
You caught an error on my part, there. I was working from an IBM-DOS 3.30 manual, but I tested it on MS-DOS 6.20 and AST/MS-DOS 5.00 systems > But it's not a solution to the problem we were looking at, which was 'how do > you find which file will be executed when you type <whatever>'. That will > show you all <whatever>s on the disk, which is no help at all. Actually, knowing the paths to all the <whatever>s should help you figure out which one will execute. Just execute the "PATH" command, which will allow you to you to read (from left to right) the order in which the system searches directories for <whatever>. The first <whatever> it finds is the one that will execute. Another alternative is to CD to the directory containing the <whatever> you want to execute. Depending on the circumstances, this may be safer and easier than re-arranging your PATH statement. (Say you just want to try something once.) > And yes, this is a problem; one of my hats is that of a Java developer, and > sometimes I need the old Java (JDK 1.1.8/Swing 1.1.1) because it's all > platform independent, and sometimes I need the new J2EE which contains some > Jini code I believe. So when I type 'javac' to compile some code, I need to > know which one's going to be used and alter my PATH if needed. If you wish to use a particular <whatever> consistently, changing your PATH statement is the better alternative - but watch that you don't accidentally execute another version from its directory. Having all your <whatever>s in separate, clearly identified directories is good practice. Boyd Ramsay [EMAIL PROTECTED] To unsubscribe from SURVPC send a message to [EMAIL PROTECTED] with unsubscribe SURVPC in the body of the message. Also, trim this footer from any quoted replies. More info can be found at; http://www.softcon.com/archives/SURVPC.html
