When I go into settings to switch WiFi onir off, I invariably get the message settings has stopped. I have to refresh it several times before I can access ss the WiFi screen. One time I had to do it 30 times! I also had this problem m on the Xperia xa so bought this phone but the problem persists.
That sounds very strange and must be very annoying to have to deal with.
Could you try and restart your device in safe mode and see if you experience the same behaviour? Just so we can see if any of your downloaded applications is the cause of this occurring when you want to enable Wi-Fi in your device. In safe mode, all downloaded applications will be temporarily disabled, so no data will be removed and they will be started again once you reboot the device back to the "normal" mode.