About 9 a.m., the two workers were riding in the elevator and discovered that the door did not open. The men, identified as Edward Tyler and Wendell Amaker, began to hit the buttons for various floors in the hope that the doors on one of them would work.

“They figured they’d try the basement level,” Captain Melvin said.

On another day, that would probably have been fine, but the rainfall on Sunday had led to severe flooding in the basement. And when the elevator neared the basement level, “it hit water and started sinking slowly, until it sank to the bottom of the shaft,” Captain Melvin said.

The two men were alone in the building, he added. There was no one inside to hear their shouts, and a security guard outside was unaware of the disaster unfolding inside, Captain Melvin said.

With a cellphone the men reached the Fire Department. While neither knew the precise address of the building, they said it was near the intersection of Richmond Avenue and Christopher Lane.

When firefighters finally found them, about an hour after their initial call, the two men were standing atop the plastic cart they had been using to transport supplies between floors. Even with the cart’s added height, the water was up to their necks, and about three feet from the elevator’s ceiling, Captain Melvin said.