In Virginia, if you are a registered independent, can you vote in a primary?

I'm a registered independent, but I may end up wanting to vote in a primary. Is this allowed? If not - how can I register for a party before the primary so that I can vote?
6 answers 6