An optometrist who stole from the NHS to supply special-needs and under-privileged children with spare pairs of glasses walked free from court yesterday after the judge conceded he had "provided a service".

Cardiff Crown Court was told Gwyn Evans, who had earlier been described as aRobin Hood figure, gave away eyewear to children who continually broke theirs and whose families could not afford to replace them. Evans, 46, of Southerndown, South Wales, admitted 41 charges of obtaining money by deception, and asked for 765 other offences to be considered.

The court was told Evans had followed an "unwritten rule" in making the fraudulent claims while he attempted to operate under supposedly "unworkable" National Health Service regulations on free eye care.

The optometrist, who runs a practice in Bridgend, obtained more than £23,000 by deception from Iechyd Morgannwg Health Authority. He was given a suspended prison sentence of nine months and ordered to pay £400 costs after Judge Michael Gibbon called for a review of NHS regulations, which allow eligible patients only one free pair of spectacles.

"Your dishonest conduct can be distinguished because in committing these offences you did provide a service to members of the public. Your patients were almost all of them children, suffering from defective vision, some of them with special needs, many of them from poor homes," he told Evans.

Though he did acknowledge that Evans had, to an extent, benefited from the fraud, the judge conceded that the optometrist was acting in the best interests of his patients and criticised the regulations on glasses as "restrictive".

Huw Evans, for the defence, told the court that his client had acted fraudulently to provide young patients with extra sets of glasses. He had also given the youngsters free swimming goggles with prescription lenses and glasses with thin fashionable lenses in attempts to encourage them to wear spectacles.

Mr Evans said that rather than being a figure of distrust in the community, his client's home village had rallied round him in support of his actions.

David Essex Williams, for the prosecution, said Evans admitted the charges of deception during a police interview and had told officers he had helped one child "because this girl hasn't got a lot going for her".

He also gave one youngster's mother a free pair of glasses to which she was not entitled, claiming them under the child's name.

The court was informed that Evans had repaid £25,000 – more than was required – to the health authority.