As long as the number of calories you eat in a day is not more than the calories you burn, eating late won't cause you to gain weight. The same meal has the same calories at 10 p.m. as it does at 6 p.m.
So why does eating late have such a bad image? One problem is that nighttime eating tends to be snacking rather than sitting down for regular meals — and lots of snack foods are low on nutrition but high in calories. Snack foods also make for mindless eating. It's easy to sit down in front of the TV with a large bag of chips planning to enjoy "just a few," and the next thing you know you're scraping up the crumbs and salt at the bottom of the bag.
In short, there's nothing wrong with sitting down to a normal family dinner a bit on the late side. But you might want to avoid post-dinner snacks — or if you get hungry, reach for something healthy, like fruit or sliced veggies. That way there's less of a chance that the foods you eat will put you over your daily calorie limit.