A man suspected of opening fire on a group of young swimmers gathered along a riverbank was arrested Friday after he emerged from woods near the scene where three teenagers were slain and a fourth person was wounded the day before.

Scott J. Johnson, 38, was dressed in camouflage when deputies confronted him after an all-night manhunt. He dropped his assault rifle as officers approached.

"We believe he was in the woods and near our officers, who were also in the woods all night," said Jerry Sauve, chief deputy sheriff in Marinette County.

Nine young adults had gathered at a railroad bridge to swim in the Menominee River Thursday afternoon when a gunman appeared and opened fire, authorities said. Investigators have not determined a motive. The sheriff said there was no communication between the gunman and his victims.

Johnson, from the nearby town of Iron Mountain, Mich., was jailed to await an initial court appearance. He had not been formally charged, and the jail did not know whether he had an attorney.

In Michigan's Dickinson County, a judge Friday issued an order for Johnson to stay away from a 24-year-old Kingsford, Mich., woman. She says he sexually assaulted her Wednesday in the area where the shootings occurred, then walked across the railroad bridge and into the woods in Wisconsin.

The order prohibits Johnson from following the woman, appearing at her home or workplace, or threatening her. Authorities did not return calls seeking comment on whether they were preparing charges in the assault. The Associated Press generally does not name people alleging sexual assault unless they give permission.

The woman told the AP on Friday night that she reported the assault to police after telling her parents about it Wednesday night. She said officers came to her home late Thursday, mentioned the shootings and asked her to describe her attacker.

"I feel bad about those other people that got killed," she said. "It's scary. It could have been me."

More than 100 law enforcers from at least 10 agencies had been called in to search for the gunman. Authorities set up roadblocks and evacuated some homes in the northern Wisconsin area just across the state line from Michigan's Upper Peninsula.

Sheriff Jim Kanikula said the assailant was only 7 to 10 feet from one victim when he fired.

"There's a saying up here that this is a great place to raise kids," said Randy Van Gasse, school superintendent in nearby Norway, Mich., where 17-year-old victim Tiffany Pohlson would have been a senior in the fall.

"That's been violated, and we don't know why," he said. "This is obviously a shock to everybody."

The other dead were identified as Anthony Spigarelli, 18, and Bryan Mort, 19. A fourth person, 20-year-old Daniel Louis Gordon, was wounded. All were from Michigan.

Niagara is about 210 miles north of Milwaukee. Across the Menominee River are Iron Mountain and Kingsford, Mich. The cities, with a combined population of about 15,000, are known for logging and tourism.