A gunman walked into a busy downtown Denver office building and shot a person multiple times before turning the gun on himself, police said Tuesday.

Police spokesman Doug Schepman said the gunman was found dead when SWAT officers arrived. The female victim was critically injured and was undergoing surgery at a nearby hospital.

Schepman said the gunman targeted the victim, and detectives are trying to determine the connection between the two. Police have not released any names.

Officers went floor-by-floor to clear the Alliance Center, a building that houses several environmental organizations and provides shared workspaces. Other buildings were locked down, and people were asked to stay away from the area.

Nicole Arnone, who works for the environmental group Earthjustice on the third floor of the building, said she was listening to a conference call with earbuds when a co-worker tapped her on the shoulder and said, "We just heard a few loud bangs and some screaming, and I think we need to go."

"We debated whether to hide in the corner or run," Arnone said, and they decided to flee. She smelled smoke and thought it was either a fire or gunpowder, she said. Arnone spotted a shell casing in the stairwell as she fled.

Once outside the building, she flagged down an officer, who took her to a bus where witnesses were being held.

Jordan Peters, who works nearby and was having coffee next door at the time of the shooting, said she saw a swarm of people running from the area.

"They were yelling that there was a man with a gun, that there was a shooter," she said. "I got my stuff and ran in the opposite direction."

Office workers in the Alliance Center streamed out of a door with their hands in the air as armed officers secured the scene.

The Alliance Center is steps from the 16th Street pedestrian mall in the trendy LoDo neighborhood near a major transit hub and about four blocks from Coors Field.