I have a 2002 kia sportage wen lock door with key horn don't sound anymore
Hello and welcome to JustAnswer!
Have you checked to make sure the horn does still work when you press the horn button? Its possible that the horn isn't working at all due to a blown fuse, horn relay, wiring issue or even the horn itself.
If the horn does work but not when locking then it could be a bad lock cylinder switch, wiring issue or the time and alarm module, but the feature may just need to be turned back on. A scan tool can be used to make sure that the lock cylinder switch is actually sending a signal that you're locking the door, if it's seeing the input then most likely the horn chirp feature will need to be turned back on.
It's possible that the lock cylinder switch has failed or has come off of the lock cylinder. This is a switch mounted on the back of the lock cylinder that is wired to the time and alarm module and provides it with a signal when you lock and unlock the door. If the module doesn't know you're locking the door then it won't chirp the horn.