Do the following.
take a step back and look at what the assignment is.
separate each segment of the program, looking at the entire thing just complicates things.
step 1. make the door go up by pressing a pb.
stop the door from going up if pb 3 is pushed OR a limit switch is made
get that logic worked out.
Step 2. make the door go down using the same type of logic
james