The Prince of Wales was cheered by locals as he visited a housing estate that featured in a TV documentary charting the lives of residents.
Charles toured the North West Youth Project and an area community centre in the Onthank estate in Kilmarnock, East Ayrshire where the series The Scheme was made.
He was given a warm welcome by residents and posed for photos with excited youngsters including Tony Craig, 19, and Kaileigh Cassidy, 15.
Kaileigh said: “I asked him for a photo and he asked why I wasn’t in school. I told him I’m looking after my mum because she’s recovering from cancer. He said that was a shame but he was pleased when I told him she was given the all-clear last week.
“I read in the paper that he was coming down and the whole scheme has been buzzing to see him.”
The Onthank estate featured in BBC Scotland show The Scheme in May 2010 when cameras filmed six families living in the area.
Charles, known as the Duke of Rothesay in Scotland, met the Cree family who featured in the documentary.
Marion Cree met the Duke to tell him about a community garden project for which they have been raising funds.
She said: “It was brilliant to meet him, he seemed really interested in the project and told us to keep up the hard work.
“We were a bit nervous, but ‘good nervous’, and now we want me invite him back to open the garden in August. It’s a big deal having a royal in Onthank and really good for the area.”
The Prince later showed his sporting side during the visit by taking part in an archery lesson and watching amateur boxers train.
Charles hit the target with his first shot with the bow and arrow, and impressed the youngsters taking part in the lesson.
Jason Wilson, 11, said: “He was really good for his first time. He didn’t hit the bullseye like me but this is my third lesson, so if he keeps practising he could be really good.”
Archery coach Jim McPike, who teaches at the North West Youth Project, said Charles has tried the sport before.
He said: “He did really well but he told me he has fired a bow before but not for a long time.
Prince Charles rounded off his week of Scottish visits by touring the Scottish and Southern Energy anaerobic digestion plant that generates energy from processing organic waste.