home *** CD-ROM | disk | FTP | other *** search
/ High Voltage Shareware / high1.zip / high1 / DIR4 / WILD401.ZIP / EXAMPLES.ARJ / WILDCARD.BAT < prev    next >
DOS Batch File  |  1990-09-20  |  1KB  |  41 lines

  1. @echo off
  2.  
  3. rem This is the first (batch) version on which Wild.EXE's idea was based.
  4. rem Included in WILD400.ARJ as a batch programming example!
  5.  
  6. if %1.==. goto HELP
  7. if %1.==?. goto HELP
  8. if %3.==. for %%p in (%1) do %2 %%p %4 %5 %6 %7 %8 %9
  9. if %3.==. goto END
  10. if %3.==wild. for %%p in (%1) do %2 %%p %4 %5 %6 %7 %8 %9
  11. if %3.==wild. goto END
  12. if %4.==wild. for %%p in (%1) do %2 %3 %%p %5 %6 %7 %8 %9
  13. if %4.==wild. goto END
  14. if %5.==wild. for %%p in (%1) do %2 %3 %4 %%p %6 %7 %8 %9
  15. if %5.==wild. goto END
  16. if %6.==wild. for %%p in (%1) do %2 %3 %4 %5 %%p %7 %8 %9
  17. if %6.==wild. goto END
  18. if %7.==wild. for %%p in (%1) do %2 %3 %4 %5 %6 %%p %8 %9
  19. if %7.==wild. goto END
  20. if %8.==wild. for %%p in (%1) do %2 %3 %4 %5 %6 %7 %%p %9
  21. if %8.==wild. goto END
  22. if %9.==wild. for %%p in (%1) do %2 %3 %4 %5 %6 %8 %%p %9
  23. if %9.==wild. goto END
  24. echo %0: Syntax error
  25.  
  26. :HELP
  27. echo.
  28. echo %0.BAT - (c) Haris Courouclis 1990
  29. echo.
  30. echo %0 is intended for use with programs that do not accept wildcards,
  31. echo such as DOS's TYPE.
  32. echo.
  33. echo It is the first (batch) version on which Cadmos Wild.EXE was based.
  34. echo.
  35. echo   USAGE: %0 command file-mask [parameters including WILD ...]
  36. echo EXAMPLE: %0 type *.txt wild
  37. echo EXAMPLE: %0 find *.txt "Test" wild
  38. echo.
  39.  
  40. :END
  41.