Unfortunately, EHs can be hard to remove like this, as you are finding out. Unlike actions, which pass their index to the action script, EH's don't do that. Here's a trick I've used to get around this sort of problem. I'll write a line of code in italics, then explain it, and so on:
-------------------------------------
_idx = pa10 addeventhandler ["hit", {}]
Here you add a "dummy" EH to the unit, in order to get it's index
pa10 removeeventhandler ["hit", _idx]
Next we remove the dummy EH. Note that this means that the next EH we add will have the same index as this one we just removed (more on this later)
_code = format [{(_this select 0) removeEventHandler ["hit", %1]; _this exec "hit.sqs"}, _idx]
pa10 addeventhandler ["hit", _code]
Here we are using the 'format' command to 'insert' the index we found above into the EH's code. Notice that when the format command is reached, OFP will turn that whole thing into a string, and instead of %1 it will have the value of _idx. So when the EH is run, whatever we found for _idx will be used in the 'removeeventhandler' command.
That's the idea behind it, you just gotta repeat for all the units you want to add the EH to.
-------------------------------------
There is one problem with this method (or any method to remove EHs), however. Let's say you have a unit with 4 'hit' EHs on him:
index code
0 {hint "1st EH added"}
1 {hint "2nd EH added"}
2 {hint "3rd EH added"}
3 {hint "4th EH added"}
Let's say you remove the EH with index 1 from the above list. Now the list of EH's on the unit will look like this:
index code
0 {hint "1st EH added"}
1 {hint "3rd EH added"}
2 {hint "4th EH added"}
Note that OFP doesn't just remove the one EH, it also changes the index of all the EHs added after that one. So let's say that when you created each EH, you stored their indexes like so:
idx0 = _unit addeventhandler ["hit", {hint "1st EH added"}]
idx1 = _unit addeventhandler ["hit", {hint "2nd EH added"}]
idx2 = _unit addeventhandler ["hit", {hint "3rd EH added"}]
idx3 = _unit addeventhandler ["hit", {hint "4th EH added"}]
When you remove one of the EH's like in the above example, suddenly these variables will NOT the index of the EH they added in, since those EH's changed indexes.
Hopefully that explaination made sense, but the short of it is: you might run into problems if you remove other eventhandlers of the same type from the unit. Or if other scripts do. Or if mods like the ECP do. For that reason I usually only remove eventhandlers shortly after they are added. But as long as you KNOW that other EHs won't be removed, you should be fine.