arduino mega 2560 questions on upload and project addvice

i am working on example 05: from the book getting started with arduino . i have the sketch done. i try to upload it gos threw i think but when i hook my arduino up to my breadboard i am having trouble with the wire diagram i half to hook up example 05: to example using a pushbutton to control the led figure 4-6 and 5-4. i tried different ways to hook them up but having trouble with placement of pin 9 and pin 7 how to place them. will to strong of a resistor affect of what i am trying to do. i am trying to fade an led in and out like on a computer when u put the computer to sleep.

PS. thank u for your help in advance.