0
[VB.NET] Showing a modal dialog box or form when the application is not running in UserInteractive mode is not a valid operation. Specify the ServiceNotification or DefaultDesktopOnly style to display a notification from a service application
March 14, 2020
|
Posted in Programming
One day I would like to show dialog box on my web page, but got the error.
but got the error
Problem
The Error Message:
Showing a modal dialog box or form when the application is not running in UserInteractive mode is not a valid operation. Specify the ServiceNotification or DefaultDesktopOnly style to display a notification from a service application
Reason:
You can not use MsgBox to Showing dialog box when the application is on IIS.
Solution
Showing dialog box via “alert” with “ScriptManager.RegisterStartupScript”
Step 1. Create a Sub as below:
Step 2. use showbox to show the message instead of MsgBox . it works.