I have a 10 month old yorkie and I started litter box training him when he was 6 months old. I bought the dog litter and he ate it

Unfortunately, he still doesn't want to use it. I never tried the spray though. I will have to try that. He is good about doing his stuff outside but when the winter comes around again I would like him to learn how to use the box so I don't have to take him out when the weather is bad.