They strode into the restaurant supply store in Harlem shortly after 3 p.m. on Thursday, four young men intent on robbery, one with a Glock 9-millimeter pistol, the police said. The place may have looked like an easy mark, a high-cash business with an owner in his 70s, known as a gentle, soft-spoken man.

But Charles Augusto Jr., the 72-year-old proprietor of the Kaplan Brothers Blue Flame Corporation, at 523 West 125th Street, near Amsterdam Avenue, had been robbed several times before, despite the fact that his shop is around the corner from the 26th Precinct station house on West 126th Street. There were no customers in the store, only Mr. Augusto and two employees, a man and a woman.

The police said the invaders announced a holdup, approached the two employees and tried to place plastic handcuffs on them. The male employee, a 35-year-old known in the community as J. B., struggled with the gunman, who then hit him on the head with the pistol. Watching it happen, Mr. Augusto, whom neighborhood friends call Gus, rose from a chair 20 to 30 feet away and took out a loaded Winchester 12-gauge pump-action shotgun with a pistol-grip handle. The police said he bought it after a robbery 30 years ago.
Mr. Augusto, who has never been in trouble with the law, fired three blasts in rapid succession, the police said, although Vernon McKenzie, working at an Internet company next door, heard only two booms, loud enough to send him rushing to a window, where he heard someone shout: “You’re dead! You’re dead!” The first shot took down the gunman at the front. He died almost immediately, according to the police, who said he was 29 and had been arrested for gun possession in Queens last year and was the nephew of a police officer. Mr. Augusto’s other two blasts hit all three accomplices, who stumbled out the door, bleeding.

One of them, a 21-year-old, staggered across 125th Street and collapsed in front of the General Grant Houses, a nine-building complex with 4,500 residents, one of the city’s biggest housing projects. Someone called 911, and an ambulance rushed him to St. Luke’s-Roosevelt Hospital Center, where he was dead on arrival. The police said he had a record of arrests for weapons possession and robbery. Another wounded man left a blood trail that the police followed to 125th Street and Amsterdam Avenue. The fourth wounded man was picked up, on the basis of witness descriptions, at 128th Street and St. Nicholas Terrace. Both were taken to St. Luke’s. The names of the men who were shot — two dead and two wounded — were not immediately released by the authorities. The two at the hospital, both 21 years old, were in stable condition late Thursday night, the police said.
Outside the emergency room entrance of the hospital, at 113th Street and Amsterdam Avenue, relatives and friends of the dead and wounded men screamed and wailed in anguish as word of what had happened spread. “No! No!” a woman cried. “They said he just died!”
Another crying woman, surrounded by family members, heard one of her relatives had been shot trying to rob a store. “Oh my God!” she wailed. “Why would they want to rob a store?” She started to scream: “Damn! Why? Why would he go to a family store? (so if it was not a family store she would be ok with them robbing.)He got money!” She slumped against the wall and began to pray. Later, a man ran into the emergency room and came out screaming, “Oh, God!” He held his head in his hands and sat at the curb, apparently devastated.

A youth about 16, crying and pacing at the emergency room entrance, slammed his fist into a yellow pole.The scene back at Blue Flame was also grim. Ordinarily, 125th Street between Amsterdam and Broadway is a placid setting: a couple of storefront businesses; Our Children’s Foundation, an after-school program; the Antioch Baptist Church and the Manhattan Pentecostal Church; the facades of the housing project looming up; a lot of passing and parked cars. The facade of the store is brick and concrete, with the words “Blue Flame” emblazoned in faded blue on the front of the three-story building.
Two hours after the shootings, the body of a man lay on the sidewalk, its upper half covered in white plastic. Gray pants and white sneakers, with the toes pointed up, were visible. And there was the inevitable crowd of bystanders. “How the hell are you going to rob someone in broad daylight?” said Sarah Martin, president of the General Grant Residents Association. Looking around at the crowd of people, she added, “They’re very upset, the people who live in this area.” I would be happy they got what was coming to them, a dead robber is a good robber.

Gene Hernandez, 47, sympathized with Mr. Augusto, but not with the would-be robbers. “If I were him, I would kill a dozen of them,” he said. “You have to protect your workers and your family. Case closed.” Stefany Blyn, who leases a commercial building from Mr. Augusto, described him as a “laid-back, unexcitable guy,” who often lounged in his chair on the sidewalk. She said she was “not totally amazed” at the robbery, because he had told her that he had been robbed several times before and that he dealt in a lot of cash in his business, which was the sale and service of stoves and other kitchen equipment. The shop opened in 1929, according to news articles about it.

“He was trying to make a living in his business,” said John E. Walker, who works at Drum Television Network, next door. Venus Singleton, 51, said she hoped that Mr. Augusto would not get into trouble over the shootings. “I hope that the gun was licensed and that he was in his rights,” Stupidity that pissed me off. she said. Paul J. Browne, chief spokesman for the Police Department, said that Mr. Augusto had not been arrested or charged. He was being treated like a witness and was still being questioned early Friday at the station house. It was unclear if the shotgun was registered, but Mr. Browne said, “There is a lower threshold for owning a shotgun in the city, a permit as opposed to a license.”