NEW YORK - United Airlines cannot be held responsible for the hijacking of an American Airlines flight and the collapse of a third World Trade Center building after the twin towers fell in the Sept. 11 attacks, a federal judge ruled Wednesday.

The airline was not responsible for the collapse of 7 World Trade Center because it had no connection to American Airlines Flight 11 or its hijackers, except that it had shared responsibility for a security checkpoint in Portland, Maine, that screened two of the terrorists, U.S. District Judge Alvin Hellerstein said. Regardless of their air carrier, all passengers at the time passed through the checkpoint.

Terrorists flew two commercial jets into the trade center towers on 9/11. Among them were Mohamed Atta and Abdul Aziz al Omari, who had passed through the Portland airport on their way to Boston, where they boarded Flight 11. Some debris from that jet's crash into the north tower pierced the facade of 7 World Trade Center, starting fires that caused the 47-story building, erected in 1987, to fall seven hours later.

The corporation that owns 7 World Trade Center sued various aviation defendants, including United, saying their negligence led to the building's destruction.

The judge said United could not have foreseen the chain of events that led to the building's collapse and bore no responsibility for ticketing, passenger check-in and boarding for the flight Atta and al Omari took to Boston, much less responsibility for the operation of the flight itself.

Other than shared authority for the lone security screening checkpoint at Portland International Jetport, "United had no connection to Flight 11 or its hijackers," the judge said.

He said it was "not within United's range of apprehension that terrorists would slip through" the Maine checkpoint, fly to Boston, proceed through another airline's security screening, board that air carrier's flight, hijack it and crash it into a skyscraper, causing another building to collapse.

Bud Perrone, a spokesman for Silverstein Properties, said the plaintiffs were disappointed by the ruling but looked forward to their prospects in a different lawsuit against United over security lapses that led terrorists to hijack United Flight 175.

"We are determined and look forward to presenting the facts before a jury, which will decide whether the defendants' insurance companies should finally be forced to pay up in order to finish the rebuilding of the World Trade Center," he said.

A message left with a lawyer for United Airlines was not immediately returned.

In dismissing a similar claim against Consolidated Edison Co. a year ago, the judge said it was unreasonable to think Con Ed could foresee the "strange, improbable, and attenuated chain of events that led to 7 World Trade Center's collapse."

A 52-story building now stands in place of 7 World Trade Center.