Unfortunately no amount of dietary changes is going to be able to pevent the disease in a hamster that has a gentic predisposition to it so the key is trying to manage the condition as best you can.
I have unfortunately had many diabetic hamsters in my time due to the fact that I've been keeping Chinese Hamsters for over ten years now and I've tended to use either Burgess Dwarf, which sadly isn't available any more or Harry Hamster as that does not use any sugars to make the food more palatable.
There is some information here about the management of diabetes in hamsters from Vectis Hamstery, a former Chinese Hamster breeder which might be worth a read:
Chinese Hamster Diabetes Management - Vectis Hamstery