how to execute an 'Alert'-windows within vb?

B

Ben

Hi,

When a user wants to start the application, aspnet checks a boolean value in
a field of the database.
If that value is 'false', then i want to execute a ALERT in javascript
telling the applicatin is closed.
This is a part of the .aspx.vb file:
Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs)
Handles Me.Load
....
dtreader = comd.ExecuteReader
dtreader.Read()
myvalue = dtreader.GetValue(0)
dtreader.Close()
If start = False Then
...... alert("application is closed")
...... window.location.href="http://mywebsite/"
else
......
End If
 
M

margelos

In c#

Response.Write("<script
language='javascript'>alert('hello');</script>");

Ο/Η Ben έγÏαψε:
 

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

Members online

Forum statistics

Threads
473,968
Messages
2,570,152
Members
46,697
Latest member
AugustNabo

Latest Threads

Top