0
Can i have that source code of javascript?
0
Hi jshelper!!
Thank you for your time and response. your advice is helpful and i sort it out. Thanks again and any one read this thread who needs to know how did i sort it can freely ask me how to use the java script for this task.
0
ASP.NET doesn't support the MessageBox (ala Windows Forms), so you are left on your own to do so. I know of 3 ways of doing it, but they all use JavaScript.
1. The JavaScript function alert() will popup a messagebox with the passed text and provide an OK button.
2. The JavaScript function confirm() will popup a messagebox with the passed text and provide the OK and CANCEL buttons - and will return TRUE or FALSE depending on which button was clicked.
3. The JavaScript fucntion window.open() which opens a new window. The function takes a few arguments including properties about the new window (size, if it has a title bar, etc.). What I don't know is how to pass information from the new window back to the main window that opened it, but I'm sure it's fairly easy.
Do some JavaScript research into these functions to better understand how they work. In your case, I think the alert() function is what you're after.
Read up on the System.Web.UI.Page.RegisterStartupScript() method. I envision your code using this method to call the alert() function when login authentication fails.
