Quantcast
Channel: Web Forms
Viewing all articles
Browse latest Browse all 23244

Message wont display

$
0
0

This code validates that the user is created in the database.  if its not, it kicks the user out.  It works properly except that the message explaining to the user what has happened is not showing up.

Can anyone help me with this please?

protected void OnLoggingIn(object sender, LoginCancelEventArgs e)
        {
            string sSQL = "SELECT employeeid from employees where EmployeeID = @EmployeeID";
            DataTable valUser = new DataTable();
            TextBox employeeid = (TextBox)LoginUser.FindControl("UserName");
            dbAccess.GetUserInfo(sSQL, employeeid.Text, ref valUser);
            if (valUser.Rows.Count == 0)
            {
                LoginUser.FailureText = "TEMP MESSAGE-- Your not in the PTO system";

                e.Cancel = true;
            }
        }

I want the message to show up in a mesage box.  I'm using C#.


Viewing all articles
Browse latest Browse all 23244

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>