This flight was delayed which caused me to have to sprint through the Newark airport to try to make my connection. United knew I had this connecting flight and knew that flight was delayed slightly, yet when I arrived at the gate I was told the door had "just been closed" with the plane still not cleared to leave the gate (which I found out later). It would've been much better if United had contacted the gate agent asking to hold the door for a passenger who had just landed. 15 minutes after I boarded, the door was reopened again for two more passengers - making my half mile sprint unnecessary. Some coordination between flights would go a long way to providing much better customer service for passengers inconvenienced by delayed flights.