Diashow code not working, full with errors

i just want it for my desktop..