YOU SAID:
I go to the toilet when I need to
INTO JAPANESE
必要なときにトイレに行きます
BACK INTO ENGLISH
Go to the bathroom when needed
INTO JAPANESE
必要に応じてトイレに行く
BACK INTO ENGLISH
Go to the bathroom if necessary
INTO JAPANESE
必要に応じてトイレに行く
BACK INTO ENGLISH
Go to the bathroom if necessary
That didn't even make that much sense in English.