Hani Honey Hani Honey - 1 year ago 144
Ajax Question

Asp.Net popup error message

Is there a way I can display an error message in a popup box? I'm using Asp.Net (C#), and on our webpage, if an order goes throug incorrectly we display an error message. Now, we would like to be able to do so using some sort of pop-up method (maybe Ajax?) - it should be able to take a string value to display the error message.

Answer Source

For a simple approach, you can have a script block that contains alert("your error message"). If you want the popup to be styled as the rest of your website then you could render your error message into a div element and use a jQuery dialog to display it as a modal dialog within your page.

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download