Roving bands of drug dealers and addicts took over whole floors at the Kenmore Hotel, the largest single-room occupancy hotel in New York City, regularly robbing and sometimes killing elderly residents for a few dollars, prosecutors said. With unlighted stairwells, broken toilets in common bathrooms and prostitutes plying their trade in the hallways, the hotel "was permeated with violence," said the United States Attorney, Mary Jo White.

In a late-morning raid, Federal agents and the New York City police arrested 18 people and took control of the 22-story red-brick building at 145 East 23d Street, where the writers Nathanael West and Dashiell Hammett once lived. A private company will manage the hotel until a court rules on the seizure.

Federal prosecutors said their takeover of the hotel represented the largest seizure ever made under a little-used 1984 law that allows the authorities to take a building being used in the sale of narcotics. The law, different from one commonly used to seize the possessions of drug dealers, allows the authorities to take someone's property if they can show there was a pattern of drug offenses at the site and repeated arrests failed to stop the trafficking.

The hotel's owner, Tran Dinh Truong, was not charged with any crime. Yesterday's action was the first step in a civil suit, but prosecutors said that he was well aware of the crimes taking place on the premises and failed to respond to repeated warnings from New York City building and law-enforcement authorities over the last two years.

Mr. Tran has bought at least five New York City hotels since he immigrated in 1975 from Vietnam where, as a shipowner, he is said to have earned millions of dollars hauling cargo for the United States military. Prosecutors said they did not know the hotels' annual profit. But they said Mr. Tran received $2 million each year solely from tenants on public assistance in the Kenmore, about 20 percent of the tenants in the hotel, which has 621 rooms.

"The guy had a cash cow," said Christopher Marzuk, an assistant district attorney from the New York City Special Narcotics Prosecutor's office. "Money was pouring in through the front door, but he didn't give a damn about anyone who lived inside."

In an interview in February, Mr. Tran said he was losing $50,000 a month at the Kenmore and could not afford the property taxes. He said 125 of 370 long-term tenants were not paying rent, and he had 16 eviction suits pending.

Mr. Tran's lawyer, Alan Lichtenberg, did not respond to repeated messages yesterday, and Mr. Tran could not be reached for comment.

Neighborhood residents have protested the hotel's deterioration for years, expressing impatience with the legal system for taking so long. In 1993, the Kenmore was cited for 362 violations by the New York City Buildings Department, the Department of Housing Preservation and Development and the Department of Health.

The Manhattan District Attorney, Robert M. Morgenthau, said that Bac Tran, apparently a relative of Mr. Tran, was convicted of bribing a New York City building inspector in 1992 in the Hotel Carter, on West 43d Street, which Mr. Tran also owns. The conviction was overturned on appeal.

Mr. Morgenthau said his office turned its investigation of the Kenmore over to Federal authorities because state forfeiture laws are relatively weak.

In a court complaint, Ms. White, the United States Attorney, argued for seizure by saying that although the police had made 122 drug-related arrests in the hotel since 1991, dealers were easily replaced and drug trafficking continued.

"Many of the individuals arrested for selling narcotics worked as security guards at the Kenmore Hotel," Ms. White said in court papers. The guards, hired by Mr. Tran and his employees, often charged drug customers $1 to $20 to enter the building.

As recently as June 4, a security guard told a police informant that he had collected $200 that day from people who wanted to enter the hotel. But that was minor, compared with other crimes: an 86-year-old woman was robbed, strangled and her body left in a bathtub, last month, the police said.

Officer Scott Kimmins, who has patrolled the area for eight years, said yesterday that he typically entered the hotel twice a day and was continually stunned at what he called horrendous living conditions.

"A lot of elderly people live here, but you rarely see them because they're so terrified," he said. "They live in tiny rooms, like living in their own prisons. Today's a great day. The Marines came in."

Prosecutors said in court papers that Officer Kimmins received death threats from drug dealers. They sometimes tried to figure out his schedule to avoid him, prosecutors said, and discussed making an anonymous complaint on him to the Police Department's Internal Affairs Division in the hope of removing him.