Dialog Box in aspx.cs

G

Guest

Hi!
I have a C# Web Application and I am trying to display a simple pop up window
to the user when a certain event occurs.

But when I call Message.Box I get the following error message:
It is invalid to show a modal dialog or form when the application is not
running
in UserInteractive mode. Specify the ServiceNotification or DefaultDesktopOnly
style to display a notification from a service application.

How can I pop up a message box in my web application ?

Any help will be appreciated!

LW
 
H

Herfried K. Wagner [MVP]

LW said:
I have a C# Web Application and I am trying to display a simple pop up
window
to the user when a certain event occurs.

But when I call Message.Box I get the following error message:
It is invalid to show a modal dialog or form when the application is not
running
in UserInteractive mode. Specify the ServiceNotification or
DefaultDesktopOnly
style to display a notification from a service application.

The code is executed on the server, not on the client. You can use a
client-side VBScript ('MsgBox') or JScript ('alert') instead.
 
G

Guest

John,

I have done the above (pop up window) using html and java. So, I find it hard
to believe that that it can't be done if the environment is .NET and C#.
Bummer!

Can I invoke Javascript pop up window from within my C# ? Help!

LW
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top