A Davidsonville man accused of opening fire on guests at a wedding anniversary party was in critical condition yesterday from a gunshot wound and injuries suffered when he crashed his car into a utility pole, police said.

A 19-year-old Annapolis woman was in critical condition as well, Anne Arundel County police said, after she was hit by a passing vehicle as she ran from the party to escape the gunfire. Three other people suffered gunshot wounds.

The suspect, Terrance C. Medley, 25, has been charged with three counts each of second-degree attempted murder and first- and second-degree assault. He also has been charged with reckless endangerment, possession of a deadly weapon and possession of a deadly weapon with intent to injure.

According to Anne Arundel police, the shooting occurred about 11 p.m. Saturday after private security guards removed Medley from the invitation-only party at the Odenton Volunteer Fire Department hall. He apparently had not been invited, said Sgt. Shawn A. Urbas, a police spokesman.

Police said Medley returned with a shotgun and opened fire. They said three people were wounded by gunfire as the approximately 100 guests fled for safety.

After crashing his car as he sped away, Medley was flown to the Maryland Shock Trauma Center in Baltimore, where authorities determined that he also had been shot. As part of the investigation, police are trying to determine who shot Medley, Urbas said.

Three security guards were arrested at the scene, police said. Edward Lee Weary, 37, of Upper Marlboro was charged with possession of a deadly weapon, a handgun, and two counts of possession of a concealed weapon, a stun gun and a knife. Edward W. Coles Jr., 18, of Oxon Hill was charged with possession of a concealed weapon, a stun gun, and James M. Marshal, 41, of Suitland was charged with possession of marijuana.

Authorities would not say who was hosting the party and what relationship, if any, the hosts had with Medley.

The 19-year-old woman in critical condition at Shock Trauma was identified as Erica Lynn Williams of Annapolis, who was struck by a vehicle on Annapolis Road as she ran from the fire hall.

Another party guest, Delvin Delonta Eldridge, 19, suffered a shotgun wound to the torso and was in serious but stable condition yesterday at Shock Trauma. Sharde April Smith, 18, of Annapolis and Erick Clayton Cleveland, 39, of Takoma Park were treated for gunshot wounds and released.