First of all, post the error. And the reason you usually get errors is because you are copy and pasting code you have no idea what it does.