Did you put that script into \hooks folder? If yes I suspect that script mentioned lacks environment setup (since hooks are executed in a clean environment). From SVN book:
For security reasons, the Subversion repository executes hook programs
with an empty environment—that is, no environment variables are set at
all, not even $PATH (or %PATH%, under Windows). Because of this, many
administrators are baffled when their hook program runs fine by hand,
but doesn't work when run by Subversion. Be sure to explicitly set any
necessary environment variables in your hook program and/or use
absolute paths to programs.
Try running with just echoes at first to be sure it is invoked by server at all:
@echo off
setlocal
echo Commit stopped 1>&2
exit 1
If it's working, then try adding this on the top of that batch:
rem Add path to Subversion executable
set path=%path%;c:\Program Files\Subversion\bin
BTW, I also found a related article here (contains also pre-commit hook example).
Update
You may also try solution for the same problem here: SVN Pre Commit Hooks
Update2
I think you are messing up client side hooks with server side ones. The first is invoked by SVN client, so parameters passed and how results are interpreted are totally client specific. I suppose the TortoiseSVN hooks are not intended to reject commits (i.e. errorlevel is not checked) but can be used for integration with other systems. See also example here. To really reject commits - you need to add these hooks on SVN server.