I have created a web site and got the user logging in with the code below where they enter an username and password and the query the database with a stored procedure to see if the username and password exists if the user does exist I put the username into a vaiable called @UserID. I also have the asp:LoginName and asp:LoginStatus working on the masterpage.
I have created another page called account.aspx and have created a form to hold the account details when the user loads this page I want there account details to automatically shown in the textboxes on the form so in the Page_Load event in account.aspx.cs page i queried the database to pull the info onto the page and it works fine if I hardcode the where clause to a username held in the databse but when I use the @UserID variable i used to log the user in I get the error
Exception Details: System.Data.SqlClient.SqlException: Must ...
Go to the complete details ...