Ive been recieving emails ok up until now and it says can't connect to server as either my user name or password are not correct but I haven't changed them I've always had the same for both name and password
Very interesting question. Are you talking about your Google account (Gmail) receiving this error? If so, i'd highly suggest just removing the account and re adding it. It should fix any sync issues you are experiencing.
To do so:
Settings > Accounts > Tap on Google > In the top right look for 3 dots stacked on top of each other > Tap on remove account
If it's another type of email account let me know and i'll do my best to assist!
I would agree with what bmh said, but if you are still having the issue... just change your passwords and do a clean password reset and login again. Thats always the easiest for me...