The complaints trickling into Frederick City Hall from renters were grim. Their homes were moldy and coated with lead paint. The electrical wiring and gas lines were not up to snuff, and sometimes tenants couldn't control the temperature of their water. And let's not even talk about the plumbing.

Vincent Hughes, the city's chief operations officer for citizen services, listened to the gripes at a series of community meetings and came up with a solution adopted by several other Maryland jurisdictions: inspect all the more than 9,000 rental units in the city and require the owners to obtain a $100 permit for each unit. In addition to cleaning up the homes, he figured the program would also generate almost $1 million in revenue.

But the proposal, which will come before a city task force Jan. 6, has caused an outcry -- not just from the city's landlords, but from affordable housing advocates, who fear that the cost of the inspections -- and any required improvements -- will be passed on to tenants and leave them out on the street.

"We might have to make a very significant investment to meet basic standards," said James Upchurch, president of Interfaith Housing of Western Maryland, an affordable housing advocacy group that owns 120 rental apartments and homes in the city. "If we make that investment, we are going to have to charge more to the people who live there. That sends chills up my back when I hear about it."

The conflict has exposed what Upchurch called a crisis in affordable housing. As formerly rural Frederick County has drifted into Washington's orbit, it has become an increasingly expensive place to live. The median cost of a single-family detached home in the county has risen from $158,000 in 1998 to $186,000 in 2001, according to the Frederick County Association of Realtors. The rise has accelerated even as the economy cooled: In November, the average list price of homes going on the market was $215,000.

Fair market rent for a two-bedroom apartment in Frederick County has risen from $820 in 1999 to $999 in 2002, according to estimates from the U.S. Department of Housing and Urban Development.

The increasing property values are a sign of health -- they mean increased property tax revenue and generally a better-educated and more prosperous population. But they also mean that the service workers who clean dishes and pick up garbage and drive buses can hardly afford to live in the city. Some renters have been forced to leave, but 42 percent of the city's population of 50,000 still rents. And a minority of those live in conditions some tenants said were closer to the late 19th century than the early 21st.

Hughes said he heard about the problems at community meetings several months ago.

"The community said we need to have programs in place that protect renters," Hughes said. "The inspectors would make sure there is hot and cold running water; no holes in the ceiling; more than three to five stairs, you have a handrail. Very basic quality-of-life issues."

Hughes said he was inspired by similar programs in Bowie, Gaithersburg, New Carrollton and Montgomery County. Some programs are less stringent than the Frederick proposal, requiring cheaper and less frequent inspections.

Montgomery County's annual licensing program has a scale of fees depending on the size of the rental unit; in Gaithersburg, a single-family home rental license is $100, and inspections take place every two years.

Frederick City landlords grew angry when they heard about the plan. Particularly unpopular was the proposal that they pay $100 for the annual inspection. The fee was to pay for eight inspectors, but any excess would go into the city's general fund.

"To quote what someone else said recently, they're trying to kill a mosquito with a massive machine gun," said Frances Myers, a member of the Property Owners' Association of Greater Frederick. "I really think this is simply a way of raising money."

Myers argued that the number of rental units that don't meet safety standards is small -- the city receives an average of 100 complaints a year -- but improvements required after inspections could be costly for landlords and for tenants.

"It will make rents go up, there's no question," Myers said. "The inspectors could make the landlord make thousands of dollars of improvements. They'll sell the building to an investor, who will modernize, and then there goes the little grandma out the door."

Myers and other landlords said that the current system, which schedules inspections within a week of a tenant's complaint, works fine. All that is needed, they say, is more education of tenants on their rights.

They have taken their objections to Hughes's task force, made up of landlords, former tenants and property management consultants. The proposal "got some mixed reviews," Hughes said. "The conversations have been robust, definitely."

He said he was going to present an amended plan, which would charge perhaps $30 for a license for three years. "The $100 program that we talked about, that was kind of a jumping-off point," he said.

He would not venture to guess whether it would pass the task force's scrutiny before going to Mayor Jennifer P. Dougherty and the Board of Aldermen.

The compromise wouldn't satisfy Upchurch, who wants to see the city build more affordable housing before introducing a program that could make housing more expensive.

"I can't in good conscience do anything at this point to take any affordable housing off line," Upchurch said. "It's a question of what's the greatest threat to people."