Hi DOBA,
A restraining order is always a good idea, because it places a document on file with the police should anything happen. That said (and I don't mean to scare you), MANY women are harmed or killed each year despite having a restraining order. It's just a piece of paper. It will help to convict a man for murdering his wife, but rarely stops the murder from occurring. If the level of stalking is limited to what your H is doing - leaving notes in your car, letters, emails, and and such - a restraining order will probably stop that. But if there is a threat of physical violence, don't depend on the police to get there in time. Definitely follow some of the advice here and do what you can to protect yourself. Some of this is coming from my own experience, many years ago, but with an abusive boyfriend. He wanted to kill me (the typical "if I can't have you, no one else will" stuff), and the police told me that they couldn't do anything until he actually made an attempt on my life, which wasn't acceptable to me. So I had to empower myself.
Will your apartment allow a dog? If so, I really believe that a large dog is your best protection. The dog only has to LOOK aggressive. I have a 70lb Samoyed who would allow entry to any burglar with a dog treat, but he looks like a wolf, and men will steer clear. I once had an attempted break-in, and they ran as soon as they saw the dog. A dog will also prevent your husband from gaining access to the apartment while you're away, and will sound off if anyone is lurking around outside. If your apartment will allow it, I'd give it some thought. Pepper spray is also a good idea. Let your husband know that you are NOT weak, and are not to be tangled with, and he may give up.
Also, tell ALL of your friends, co-workers, etc what is going on. Make sure that everyone knows about this. That way, if someone sees your H lurking about, they'll alert you to it. If things persist, have a friend call and check on you at night.
A personal alarm is also a great thing to have. I used to have one (batteries ran out). It's a small device that you carry with you, if threatened, you press the button and they are absolutely deafening. Will definitely scare an attacker off. Not sure where you would buy one, maybe a sporting goods store? Just another thought.
Hang in there and hang tough.
Kathy