This question implies that hypnosis does something you wouldn’t want it to do, and if that’s the case, the question should rather be: Can you be made to do anything you don’t wish to with the use of hypnosis. But to answer the original question: no one can make you enter the hypnotic state if you don’t want to unless you believe they have the power to do so. So now that you know that it can only happen if you think it can, you need to adjust your belief if you fear that someone would suddenly put you in a hypnotic state.
To address the other question: can you be hypnotized to do something you don’t want to do; that’s also not possible unless you believe that the hypnotist has this power. Think of it as a rental contract. If you include in the agreement that he can do something you don’t want, he has this opportunity. But since it is your mental contract, you do not include this. I won’t encourage anyone to seek out a hypnotist if they believe that the hypnotist has the power to make them do something they don’t want to. If you didn’t want a particular person to enter your house without your permission, would you give them a key? There’s no point in doing that, is there? You can safely consult a hypnotist when you know that he can only suggest things you can accept or reject.