MONCTON, N.B. -- A heavily armed gunman suspected to have shot three Mounties dead and injured two others in Moncton, N.B., was spotted Thursday morning but police were unable to apprehend him after he went into a wooded area, the RCMP said.

The most recent sighting of the suspect was just after daylight Thursday and while police were able to positively identify him, he evaded capture, said Assistant Commissioner Roger Brown, the Mounties' commanding officer in New Brunswick.

"This is working through your worst nightmare," Brown told a news conference where he appealed for public calm in a city that has been under a virtual siege since Wednesday evening.

"This is a very, very dangerous situation as we speak."

Supt. Marlene Snowman said officers were unable to confirm the identity of the suspect on two other occasions when he might have been sighted.

Police including tactical officers continued to search for the shooter since their manhunt began Wednesday at around 7:30 p.m. when they responded to a call about a man walking along a road with what was believed to be a gun.

After the call, shots were fired and officers called for backup, Snowman said.

Brown said police officers from across the country have been brought in to help arrest the suspect.

"The RCMP family is hurting," he said. "Greater Moncton is hurting as is New Brunswick as is our country."

Police were searching for Justin Bourque, a 24-year-old Moncton man who was wearing military camouflage and carrying two rifles in a picture of him released by police on Twitter on Wednesday night. They urged people with any information on his whereabouts to call 911.

Snowman said Bourque was carrying high-powered firearms, is not known to the police and investigators were trying to piece together his background.

Residents in the area where police searched were urged to stay inside their homes and lock their doors.

The RCMP released a map of a large swath of the northwest section of the city, including a heavily wooded area, where they wanted people to remain indoors.

A large number of police officers could be seen in a part of the perimeter with their weapons drawn, some peeking around buildings. Others were patrolling streets within the cordoned off area. Armoured security trucks were also visible.

Officers, including members of a tactical unit, were seen in front of one building.

Police also warned people to expect roadblocks and traffic disruptions. Schools and government offices were closed, buses were pulled off the roads, and surgeries at the Moncton Hospital were cancelled.

Brown said the two wounded officers underwent surgery in hospital Thursday and their injuries are not considered life-threatening. He said he met with the families of the officers who were shot.

"As you can all imagine, they're hurting," said Brown. "There's actually no way to describe the level of hurt."

He did not release the names of the officers who were shot because police were still notifying relatives.

Mayor George LeBlanc was visibly shaken by what has happened in his normally quiet city of 69,000.

"Never in my darkest dreams did I ever think that we would be facing what we're facing today in Moncton," he told a news conference. "Moncton has always been a special community. If this can happen in Moncton, it can happen anywhere."

Premier David Alward implored residents to heed the RCMP's warnings to stay inside their homes.

"It's so important that people stay locked down in their homes and stay off the streets and allow the RCMP to do their job," Alward said in an interview.

"My heart goes out to the families of the fallen officers and the wounded officers as well. My heart goes out to the community right now, to the families who are locked down and I can't imagine the feeling that people are going through."

Daniel St. Louis, a commercial photographer in Moncton, was among the first on the scene Wednesday around 8:30 p.m. when he came across two police vehicles on different streets with blood visible inside.

He said no one was around, except for a few curious neighbours peeking through their front doors.

One of the vehicles, a marked police cruiser, was surrounded by shattered glass. The other, an unmarked SUV with its lights still on and the driver's side door left open, had several bullet holes through its front windshield.

St. Louis, 51, said he saw something shortly after that will always haunt him.

"I walked over and I saw two feet, facing the street, toes up," he said. "I realized, 'Oh my God. There's somebody down.' As I got close, I realized it was an officer and this is not a good situation."

St. Louis said he doesn't know what to make of the tragedy.

"Our quiet little city, what is going on here?" he said. "How is this happening to us? It always happens to somebody else."

Prime Minister Stephen Harper offered his condolences to the families, colleagues and friends of those affected by the shootings.

"This should obviously remind us that our men and women in law enforcement put their lives on the line every day to serve and protect us as Canadians," Harper said while in Brussels.

"Our thoughts and prayers are with the families of those killed and also the others wounded in this terrible incident."

Based on information from the RCMP's Honour Roll page on its website, the last Mountie to die from a gunshot was Const. Douglas Scott on Nov. 5, 2007. He was shot while responding to a call for help involving an impaired driver at Kimmirut, Nunavut.

The most recent police officer killed in the line of duty was Const. Steve Dery of the Kativik police force in northern Quebec. Dery, 27, was shot and killed after he and another constable responded to a domestic violence call on March 2, 2013.

The shootings in Moncton also brought back memories of an RCMP tragedy in Mayerthorpe, Alta., on March 3, 2005, when Constables Anthony Fitzgerald Orion Gordon, Lionide (Leo) Nicholas Johnston, Brock Warren Myrol and Peter Christopher Schiemann were shot and killed.