Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.
Just be sure to follow the instructions. Don't skip a step or decide you know better than what the instructions tell you to do. Also note some good 3rd party guides on how to do it tend to be released e.g. by iFixit.
 
Hard drive - replaceable
RAM - replaceable
Optical drive - not replaceable
Battery - not replaceable

Now, swapping non-replaceable parts does not void the warranty of the entire machine. Talking to a Genius Bar employee recently, it means they are NOT allowed to do service anything related to that part if it has non-stock compontents (i.e. if your 3rd party battery dies, don't complain to Apple). I assume this policy has its limits (again, if your 3rd party battery causes the laptop to burst into flames, don't complain to Apple), but if you had replaced your optical drive with a hard drive but for some reason the display died, they would still replace the screen.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.