I think had he visited his parents before he would not be under the influence of the protective magic that had kept him safe all of those years prior, and it would have been harder to protect him form Voldemort had he visited his parents grave.
The protective magic that he had against Voldemort lasted under two condition.
- He was underage (<17)
- He continued to live at a place he c
an call home which belonged to a blood relative of his mother. (aka he was under his sister's protection)
When he is at Hogwarts he is under the protection of the school and Dumbledore along with the other professors (give or take a few).
Had he gone to his parents grave before the last book then I presume that he would have had difficulty getting there because:
- It would have been difficult, since his Aunt and Uncle were certainly not going to let him go out of the house. Or rather they certainly weren't going to accommodate him any further than they had to.
- The order would have probably not allowed him to.
And chances are he would have been out in the open and may have been vulnerable to attack by visiting his parents grave.
From a plot standpoint
Having never visited his parents grave before this point, builds up Harry's desire to visit his parents grave more and more. Leaving it as a possible destination that Dumbledore, or the Death Eaters wanted him to eventually end up in, in the hopes of passing on a message or capturing him.
From my perspective of Harry
The thought just hadn't occurred to him until now.
Up until he got to Hogwarts, he just thought his parents died in a car accident and he was fairly young. At that age I wouldn't have thought of visiting a grave.
And throughout the series he gets glimpses of their lives.
Philosophers Stone - Sees them in the mirror
Chamber of Secrets - He's more focused on his own self discovery, how is he like/unlike the dark lord
Prisoner - Spends the summer with his surrogate family (Weasley's) | He discovers his parent's killer/ oh no wait his parent's best friend and gets a figure in his life which can serve as his surrogate father. | Believes his father saved him from the dementor's kiss
Goblet - He is thrown into a situation in which Black helps harry potter along at times and he sees his parents at the end of the book again
Before this point he probably could have visited his parents. But the Dudsleys wouldn't have allowed it.
After the attack by the dementors at Pivot Drive however it's clear he would become much harder to protect, from there on out.
Order of the Phoenix - Feels left out and starts his own DA classes and creates a kind of new "family" with other students. See's his father as he was as a young man. and Looses his godFather
Half Blood Prince - Develops a sort of parent/son relationship with Dumbledore
Deathly Hallows - He lost a lot of his "family" ties, and ran out of resources. What is there left that he has yet to see. He didn't have to care so much about visiting his parents grave before because he had many new memories, new discoveries of who they were before he ever had to visit them.
His desire to see his parents now more than any other time is a culmination of how the events transpired. He didn't have the time to care before. He most certainly had the thought of visiting them before, but it wasn't until now where he is not taking classes, he has a lot of time where there is seemingly no progress being made in his quest, no hint as to where to go next. Where else does he have to go?