Start by helping us by posting your code in code tags. Did you get a warning that the code was not on code tags when you posted it ?
Please follow the advice given in the link below when posting code, in particular the section entitled 'Posting code and common code problems'
Use [color = red]code tags[/color] (the </> icon above the compose window) to make it easier to read and copy for examination