The deadly Mill Valley-area shooting that sent residents scrambling for safety erupted when the owner of an apartment complex attempted to talk to a tenant about an eviction, prompting the tenant to grab a revolver and shoot the landlord and his daughter before turning the gun on himself, authorities said Friday.

The owner’s daughter, 30-year-old Sabrina Elizabeth Lew, died from the wounds she suffered Thursday afternoon, while her father, 84-year-old Leonard Lew — who’d had at least one previous dispute with the alleged gunman — was being treated at a local hospital, officials said. Both victims lived in Mill Valley.

The Marin County Sheriff’s Office said the deceased killer was Victor Aurelino Lugo, 71, a resident of the modest, two-story complex at 939 East Blithedale Ave., just west of Highway 101 beside the main route into Mill Valley. Agency officials said he argued with the owner and his daughter after learning of his pending eviction, then opened fire.

The shooting was first reported by a neighbor who called 911 at 3:44 p.m., and sheriff’s deputies arrived two minutes later to find the wounded Sabrina and Leonard Lew — who was alert enough to provide the name of his alleged attacker — before evacuating them to ambulances, officials said.

At that point, deputies didn’t know where the gunman had gone, so they put out an “active shooter” alert as they swarmed the complex with guns drawn and helped residents flee to safety. Some neighbors locked their doors as deputies cordoned off streets. Soon, authorities instructed people over a wider swath of Mill Valley to shelter in place.

Shortly after 5 p.m., the sheriff’s tactical team initiated a “high-risk search” of the complex and entered Lugo’s apartment, where they reported finding him dead from what appeared to be a self-inflicted gunshot. A revolver was found lying at his feet. Officials said they believe Lugo used the same weapon to shoot his victims.

Lt. Steve de la O, a sheriff’s spokesman, said he couldn’t comment on whether Lugo had a criminal history. But he said Lugo had called authorities in January “for advice regarding a living situation.” Lugo then met with a deputy about a dispute he was having with the building owner, and he told the deputy that the argument had not turned violent.

The two men had disagreed about alterations Lugo wanted to make to his apartment, said de la O, who would not elaborate.

Leonard Lew remained in the intensive care unit at Marin General Hospital in Kentfield on Friday. Investigators had not yet been able to speak to him because of his condition but said he is expected to survive.

The two victims were listed as having addresses at the apartment complex as well as at a nearby house in Mill Valley, where neighbors said they lived.

On Friday morning, the mood was somber at the complex, which sits in a tree-lined neighborhood and has a courtyard surrounding a pool. A notice from the Marin County coroner was posted on the alleged gunman’s door on the second floor, barring entry while investigators continued to sift through the scene.

A woman who answered a phone listed as belonging to Leonard Lew at one of the apartments said, “We are not taking any calls right now. We’re in the middle of a family crisis.”

Al Bedrosian, who lives across the street from where the attack occurred, said the shooting struck a chord with him.

“It’s a sad situation. It brings the reality of gun violence ... right to our driveway,” he said outside his home Friday. “We’re still trying to process the reality of what happened. It shows you something like this can happen anywhere, even in this idyllic suburb of Mill Valley.

“Some people have commented, ‘Why did he have access to a gun?’” Bedrosian said. “It brings the whole mental health thing into play. Were there mental health issues? What caused him to snap like this?”

Robin Kaukonen, who moved a few houses down from the Lews’ Mill Valley house in 2002, said she knew the family as “soft-spoken,” “quiet” and “unassuming.”

Kaukonen said she saw police helicopters overhead Thursday night but didn’t know anyone had died or that a shooting had involved a family that lived on her block. Kaukonen said she would see Sabrina Lew, and sometimes her mother, out walking the family’s dog, with Leonard Lew working in the yard.

“It’s pretty shocking. I don’t know them super well, but they’re really nice neighbors. I can’t even imagine that Lenny and his wife lost their daughter,” she said, her voice breaking. “And I wish them the best.”

Chronicle staff writer Annie Ma contributed to this report.

Sophie Haigney and Jenna Lyons are San Francisco Chronicle staff writers. Email: sophie.haigney@sfchronicle.com, jylons@sfchronicle.com Twitter: @SophieHaigney, @JennaJourno