The enterprising boy managed to snap himself with the monarch in the background - although she did not seem entirely amused by his antics.
The Queen, who was accompanied by Prince Philip, was visiting Belfast.
In a speech at the City Hall, she said that she was witnessing how locals were working together for the common good.
She said: "I know there are many challenges ahead and peacemaking is not always an easy task.
"But you have come this far by turning the impossible into the possible; and, as you face the future and difficulties that may appear insurmountable, always remember that the thoughts and prayers of millions, including my own, are with you."
The Queen added: "The world yearns for examples of positive transformation and of people overcoming differences.
女王接着说道:“全世界都期盼着有一个好的结果,与克服了困难的人们作为榜样。”
"I hope and believe that Belfast will continue to be one such living example, and I want to thank you - all of you - from every part of this city for the hard work and dedication which you and your families have given to help reshape the city of Belfast and the lives of all the people who live here."
The Queen gave the short speech at a special banquet in her honour after visiting Crumlin Road Gaol with Stormont First Minister Peter Robinson and Deputy First Minister Martin McGuinness - both of whom spent time in the cells during the Troubles.
女王在北爱尔兰议会首席大臣彼得·罗宾逊和副首席大臣马丁·麦吉尼斯的陪同下参观了Crumlin Road Gaol——这两位大臣在北爱尔兰动乱期都曾被关进监狱里。
Before their engagement at City Hall, the Royal couple stopped off at the nearby St George's market.
The Queen, who was wearing an yellow Angela Kelly coat and hat, and the Duke chatted to local traders as they walked round a diverse range of stalls.
At the end of her walkabout, chairman of the traders Pat Dyer presented the couple with a hamper packed full of locally made products.
His three-year-old grandson Jack Morgan gave the Queen a cushion with an image of a helicopter on it for Prince George.
"He's been practising and he said when he handed her the cushion 'this is for baby George'", Mr Dyer added.