If SetScroll can only be either True or False (1 or 0), you can simplify the code a little:
If MouseDown(1)
If MX>711 and MX<790 and MY>0 and MY<17
SetScroll = 1 - SetScroll ; This will toggle SetScroll between 0 and 1
Endif
While MouseDown(1)
Wend
Endif