programm is working again and some small changes