I think that

SHELL '%COMSPEC% /C ""%USERPROFILE%\DESKTOP\NOTEPAD.EXE" "%TMP%\LOGON.LOG"" '

is more correct because the rules posted above state that the first and last quote will be stripped and the remaining text will be passed as the command string.
_________________________
Home page: http://www.kixhelp.com/hb/