Here is my modified BAT file. Ive never messed around with BAT files much, but what does /p and /w mean? I havent googled it yet, which I probably could find an answer pretty quick.
Question: Rather than typing "end" to end the BAT file, is it possible to end it if the user closes the window? I tried doing this, but it network drive doesnt get deleted, and I get an error the next time I run the BAT file.
--------------------------------------------------------- @echo off net use x: \\NETWORK PATH x:
:BEGIN set /p str=Enter Item Number:
IF EXIST %str%.pdf GOTO RUN
echo Item not found
IF %str% == end GOTO END
GOTO BEGIN
:RUN START /w %str%.pdf
:END
c: net use x: /delete
-------------------------------------------