It is possible that you created a script with some name, but when you try to add this script to the "script effect" field, your script does not appear in the dropdown list of choices. That is because you defined the script with the wrong type. Bring up the script editor on your script. There is a dropdown field at the top for the script type, with choices "script", "spell effect" or "object". Make sure "spell effect" is selected. Then the next time you bring up the effect dialog box, you will see your script in the dropdown.
Thank you, I've got that part working now

but I don't understand what I've done wrong here:
scn 00KleptomaniacHealScript
begin gamemode
if getminorcrimecount += 1
addspell 0Kleptomaniachealspell
modactorvalue karma 1
else
endif
end
This is the script I was originally wondering about the begin block for, I'm trying to get it to add "0Kleptomaniachealspell" when I steal something, however it won't let me save the script... :\