:sigh:
YouTube videos of "how to code security" ... about as useful as a tissue-paper kettle.
Stop trying to code from YouTube - it's pretty clear that the author has absolutely no idea what he is doing.
Never store passwords in clear text: it's a major security risk. Always hash them, and compare the hashes.
Password Storage: How to do it.[
^] explains - the code is in C# but it's pretty obvious stuff.
Without your
UsersTableAdapter.LoginQuery
code we can't tell exactly what is happening there, but the error implies that one or other of your parameters is wrong - the system is trying to cast it to a
Boolean
value before it passes it to SQL.