go right back to basics.
you need to try to work out:
what he is protesting about (interrupting a game; doing something he doesn't want to do; doing something that worries him)
why he is protesting (to get attention; to delay doing something he doesn't want to do; out of habit)
and then tackle it.
so, eg. if he is actually quite worried about some aspect of the toilet - does he feel insecure on the seat? does the noise of the flush worry him? does he hate washing his hands? - then you can try to build up to that aspect of it.
I am sure you have the comfort/security thing worked out. if it is noise, you can reassure him that you won't flush while he is there. for a while we used babywipes instead of hand washing, because it was less of an issue.
maybe go right back and build up in tiny steps.
what is his absolute favourite thing in the whole world? that he would do anything for? it could be standard eg a chocolate button, or less standard -a tickling game, or even his favourite dvd (we used a dvd initially).
to begin with, make sure this favourite thing is only available after the criteria you set. you coudl go right back, to make it really unthreatening, to eg getting him to go and touch the toilet door (while closed). then he gets his treat. do this randomly, with no other expectation. and reward him instantly for doing it. the idea is that you are retraining him to think that going to the toilet is a better idea than not (for his sake, not yours!), so it has to be motivating enough.
then add the next step, but only when he is fully comfortable with that one. so, he goes and opens the door.
then maybe he opens the door and stands inside.
then opens the door, stands inside next to the toilet.
and so on. you could, if you wanted to, make this a regular thing - eg every half hour, in the hope of building up a timed routine (we use a time routine now - I prompt after each meal, and we have success with that), or you could go for randomly, pick whichever suits your lifestyle better 
the key is to only place a demand on your ds that he can easily and comfortably meet - then there is no reason for him to want to protest instead of getting his favoured object/dvd/game. and slowy build up the demands, so that he doesn't feel threatened at all.
make it more interesting (and rewarding) for him to go than for him to not go.