It appears that PrintUsers.exe
expects to find the file doNotEdit.txt
in the current directory.
The best solution is to change that program to look for the file in the same directory as the program itself is located but, if that is not possible, get Excel to change the current directory before running the program, i.e. insert
ChDir ActiveWorkbook.Path
prior to invoking Shell
.
Also, as Yahya Hussein mentioned in a comment, spaces inside paths can cause issues. There aren't any in your specific situation but, to ensure you don't have problems in future, consider using something like
myFile = """" & ActiveWorkbook.Path & "\PrintUsers.exe"""
ChDir ActiveWorkbook.Path
Shell myFile, vbNormalFocus