EE was moving backhoe down a ramp into the coal pit. The door on the machine was in the open position, the operator thought the door was latched in the open position. The door was not latched so while he was moving down the ramp he was holding onto the door jamb of the machine. The machine hit a bump causing the door to swing closed on his hand.