Hello TechKnow members and visitors!
Like everyone probably has experienced, sometimes you need to remove trailing spaces from a variable.
I've seen many tricks to pull this off, even some using linux binaries compiled for Windows.
However, it can be done more easy:
if "%TIP:~-1%"==" " set TIP=%TIP:~0,-1%&&goto :SQUEEZER
Just smash those 2 lines in your batch file, it will goto :SQUEEZER every time a trailing space is detected, when no spaces are detected, it will move on.
Sometimes it can be as simple as one would imagine