This question already has an answer here:
- the dinner vs. dinner (grammar question) 4 answers
As said in that commentary, to have a dinner isn't ungrammatical, but implies a dinner for a specific reason. Examples are:
- we're having a dinner in his honour
- we're having a birthday dinner for you
but the difference is totally unclear for me. What is changed, if I'd say we're having dinner in his honour, for example.