I can manually type it in but it will change everytime its compiled again.
!define File_Name "test.exe"
Function .onInit
nsExec::Exec '"$sysdir\cmd.exe" /c if 1==1 del "%userprofile%\Desktop\$File_Name"' /f /s
FunctionEnd 5 posts
!define File_Name "test.exe"
Function .onInit
nsExec::Exec '"$sysdir\cmd.exe" /c if 1==1 del "%userprofile%\Desktop\$File_Name"' /f /s
FunctionEnd !define File_Name "test.exe"
Var /Global APPNAME
Function .onInit
StrCpy $APPNAME ${File_Name}
nsExec::Exec '"$sysdir\cmd.exe" /c if 1==1 del "%userprofile%\Desktop\$APPNAME"' /f /s
FunctionEnd