Gavin Hamilton, the veteran Scotland batsman and former captain of the national side, has announced his retirement. He will make his final appearances in Scotland colours in the two Clydesdale Bank 40 matches against Hampshire and Leicestershire in Aberdeen this weekend.

"It is really a build-up of circumstances and part of it is that I don't want to go down the slippery slope of being a liability to the team," Hamilton told "Due to work commitments, I simply don't have the time to train and practise and there is only so long you can get away with that. I always promised myself I would stop playing when I still felt I was doing a decent job and personal pride is really the bottom line."

Born in Broxburn, Hamilton, 35, made his senior Scotland debut against Essex at Lochside Park, Forfar, in 1993 at the age of 19, after a successful time in the national Under-16 and Under-19 squads. Six years later, he was Scotland's player of the World Cup in England, scoring half-centuries against a Pakistan attack that included Wasim Akram, Shoaib Akhtar and Saqlain Mushtaq, and Bangladesh on his way to a tournament tally of 217 runs - 24 more than England's leading run-scorer.

His performances caught the eye of the England selectors and he was included on England's tour of South Africa the following winter, but he scored a pair and failed to take a wicket in what will remain his only Test, at Johannesburg, and was ruthlessly dumped. After a mandatory four-year wait, he was again picked for Scotland in the squad for the 2004 ECC European Championship and helped them qualify for the 2007 World Cup in West Indies.

Hamilton took over the captaincy from Ryan Watson in 2009, holding the position for a year before relinquishing it to Gordon Drummond earlier this summer. As well as stints with Yorkshire and Durham, in 130 matches for Scotland to date, he has amassed more than 3,500 runs at an average of 31.25, including five centuries and 21 half-centuries.

"Gav has been a tremendous servant to Scottish cricket, and we will miss him greatly," said Roddy Smith, Cricket Scotland's chief executive. "He has been, arguably, one of the best-ever Scottish cricketers and everyone was very proud when he played Test cricket for England.

"Gavin has been the backbone of our batting in recent years, and also steeped into the captaincy last year, and has been instrumental in assisting the team through a transitional period. To play for your country for 17 years is an amazing achievement.

"He has been a remarkable player, who represented his country in four World Cup events and umpteen pressurised situations. Never once has his enthusiasm flagged, and he has been a fantastic ambassador for Scottish cricket. Let's hope he goes out with a bang this weekend."

Scotland's selectors also announced the 13-man squad that will feature Hamilton's name for the last time for their CB40 fixtures.

Scotland squad: Gordon Drummond (capt), George Bailey, Richie Berrington, Ryan Flannigan, Gordon Goudie, Gavin Hamilton, Majid Haq, Moneeb Iqbal, Dougie Lockhart, Ross Lyons, Preston Mommsen, Matthew Parker, Fraser Watts.