Next time, if you didn't learn your lesson, the day you get a sunburn, fill a cup with about 50% vinegar/50% water. Take a rag/bandanna and wet it with the solution and place on the burn for a while (not sure how long, I leave it on a while, rewet, then do it again).
Not scientific, but seems to help. I get a burn every year, and this takes the pain out, and seems to help it heal up faster.
Straight vinegar stings like a beech!