In american english, yes, you can use good evening to bid someone farewell.
It sounds a bit formal, but it wouldn't sound incorrect. A punk on a subway might not say it, but a gentleman would.
This works ESPECIALLY well when you are very angry, you can shout it at them and sound very sarcastic as you do not wish them to have a good evening! (same with "good night", "good day", and "good morning")