Is your dog neutered?
Regarding the location of the rash, is it under his anus or is it located high on his thighs between his legs?
Maybe he squatted on some kind of grass or something that irritated the area, or maybe he has humidity and dampness bothering him.?
It is a good idea to try and find the source of the problem so that he won't need medication and creams for too long.
Please have pets spayed and neutered,
and wearing a collar with an ID tag.