Audio By Carbonatix
At least sevenpeople have been killed and more than 30 injured after a 14-year-old boy opened fire at his home and school on the outskirts of Thailand's capital Bangkok.
The student killed his grandparents and five teachers before taking his own life, Thai Prime Minister Anutin Charnvirakul told reporters. The attacker still had "more than 30 bullets left" when he turned the gun on himself, the PM added.
Nine of the injured people remain in a critical condition, authorities added.
The school in Nonthaburi province is a local branch of the renowned Debsirin School, which in Thailand is widely associated with educational prestige.
Police were deployed to the scene during the active shooting.
National police chief police general Kittiratt Phanphet told reporters that forensic officers had found the gunman's shots were quite accurate, with several hitting the vital spots on the body.
The PM said the attack was "well prepared" with "clear steps and clear goals".
The attacker has not been publicly named.
Authorities earlier warned people to stay away from the area and for those in trapped in the building to hide and wait for rescuers. At one point police warned in a social media post that the shooter was in the school's computer room.
The Debsirin School, founded in Bangkok in 1885, is one of Thailand's top secondary schools with branches across the country. It counts many prominent Thai figures as its alumni, from diplomats and athletes to several prime ministers.
A seventh-grade student, who fled the building, told the BBC that she was in class when she saw the gunman walking from room to room.
When he reached her classroom, he shot the teacher standing near the entrance, she said. She added that she couldn't see anything else after that.
Another student told Reuters that he had thought the sound of gunshots were firecrackers going off, or someone banging an object.
"There were many shots: bang bang bang. Then it went quiet. Then it started again."
The 9mm handgun used by the shooter belonged to his grandfather, a former teacher, police said.
Students and school staff were seen fleeing from the scene, and those waiting outside the Debsirin school looked visibly distraught.

0:59Students shelter in classroom as gunshots heard
In a post on social media, the school later shared a call for blood donations.
Other schools in the vicinity suspended classes so students could return home early.
PM Charnvirakul expressed condolences for the victims of the school shooting. He said the tragedy "shouldn't have happened", adding "this is why the government do not allow [citizens] to possess firearms".
"I don't just feel sorry for the victims but I feel sorry that this happened. How can this happen in our country," he said.
Thailand has strict gun laws, which punishes the illegal possession of arms with up to 10 years in jail. But enforcement of these laws has been an issue.
The country has one of the highest rates of civilian gun ownership in South East Asia. It is estimated that about 40% of these guns are illegal.

Latest Stories
-
“I represented the President, not myself” – Nana Yaa Jantuah responds to Afenyo-Markin’s remark
4 minutes -
Mahama names Kenneth Gilbert Adjei as Defence Minister to replace late Omane Boamah
16 minutes -
Mahama names Zanetor Rawlings for Environment, reassigns Ayariga to Local Government in first reshuffle
31 minutes -
Pampaso chiefs invoke curses on Kumasi Mayor, Police Commander, Interior Minister over disputed land
33 minutes -
Nine suspects arrested in connection with Fiapre Zongo robbery
36 minutes -
Ethiopia’s Addis Standard editor Yonas Kedir allegedly abducted as rights groups warn of media crackdown
38 minutes -
Norway call for Infantino to resign as Mexico and Argentina back president
40 minutes -
Trump imposes 15% tariff on key chip material to counter China
40 minutes -
Seven killed after Thai teen shooter opens fire at home and school
42 minutes -
Photos: Mahama unveils cenotaph in honour of late Omane Boamah
43 minutes -
‘Our forests are breathing again’ – Armah Buah honours Murtala Mohammed’s environmental legacy
48 minutes -
Greater Accra Minister gives developers, occupants at Kpeshie Lagoon 21 days to vacate
52 minutes -
I wouldn’t be hurt if Afenyo-Markin’s ‘disrespectful’ comment was made privately – Nana Yaa Jantuah
1 hour -
UMaT commissions demonstrative underground mine to improve mining education and skills training
1 hour -
Gold Fields Foundation supports Tarkwa Prison with 20-acre oil palm project for inmate rehabilitation
1 hour