Thanks for your help, pg. Now I have no errors present on runtime (so it says). The messages I'm trying to send aren't working, but atleast I've got a start on it now.
Maybe I should have worked with perl a while longer before trying to tackle something like this :S.