[B]I to have an 06 HHR and have had the same proplem. I ended up replacing the shifter ?
After getting the old shifter out of the console I could see what a few members on here have stated what causes this problem.
Before I totaly unhooked the wire plug I pushed the small pin that activates the micro switch that allows the key to be removed ?/ All I did was push the pin back in so that it hits the switch on the right side of the shifter. As soon as I tried to pull the key out it came right out.
I did install the new shifter but plan on seeing if I can epoxy it in place so I can keep it on the shelf, I also have an 09 HHR and know of 9 or 10 local[ HHR's that I have contact with the owners off and on. If they have a problem we can swap out the shifter and save them the price of a new shifter at $160. It only takes about half and hour to do the swap.
May I sugust you remove the top parts of the console around the shifter stick, reach in on the left side and see if the little rod has come lose and moved to the left and away from the switch ??
With mine it tool 60,000 miles to happen.