Quote:
Rather than using an ExecuteScalar function which can return only a single value and, thus, would require a second call to the database, I would change the query and use ExecuteReader so you can retrieve ALL the info you may need at once. One call to get everything you need is usually better than 2 calls for 1 piece of data. But, yes, you could create a second ExecuteScalar to get UserID.
Thank you I will think. I work long to get login for working correct. I am afraid to change and then it messed up again..
Quote:
Second question, do you really need 2 separate forms for Admin and User or are they really pretty much the same form with certain controls being visible or not? I would think they would be the same except the admin version would show some extra buttons/menus to Add/Edit/Delete and that sort of thing. If it is like that you could have those controls invisible by default and if UserID is Admin then make them visible.
Yes admin and users go to different forms..