how to display the message box in asp.net

Please support our ASP.NET advertiser: Intel Parallel Studio Home
Reply

Join Date: Nov 2008
Posts: 19
Reputation: krany18 is an unknown quantity at this point 
Solved Threads: 0
krany18 krany18 is offline Offline
Newbie Poster

how to display the message box in asp.net

 
0
  #1
Nov 14th, 2008
hai to all


how to display the message box in asp .net
why means while i am creating database i want to dispay a message like..


"connection is created" like this

how it is display

please give me the answer
Reply With Quote Quick reply to this message  
Join Date: May 2008
Posts: 144
Reputation: sierrainfo is an unknown quantity at this point 
Solved Threads: 9
sierrainfo sierrainfo is offline Offline
Junior Poster

Re: how to display the message box in asp.net

 
0
  #2
Nov 15th, 2008
Try to following code and it's insert after your connection string code.

Dim strMessage As String
strMessage = "Connection is Created"
'finishes server processing, returns to client.
Dim strScript As String = "<script language=JavaScript>"
strScript += "alert(""" & strMessage & """);"
strScript += "</script"
If (Not ClientScript.IsStartupScriptRegistered("clientScript")) Then
ClientScript.RegisterClientScriptBlock(Me.GetType(), "clientScript", strScript)
End If
Reply With Quote Quick reply to this message  
Join Date: Nov 2008
Posts: 5
Reputation: jazz.learner is an unknown quantity at this point 
Solved Threads: 0
jazz.learner jazz.learner is offline Offline
Newbie Poster

Re: how to display the message box in asp.net

 
0
  #3
Nov 18th, 2008
HI,
To display a message box in asp.net you must use javascript in your html view of your form.Code is as followes.

In head teg of HTML View of your Web Form write the following code
<head>
<Script language="JavaScript">

function showMsg()
{
alert("Your message Here");
}
</Script>
</head>
To Call this function write the following code in ur Page_Load event code in (C#)

UrControlid.Attribute.Add("OnClick","return showMsg();");

I hope It will work.
Reply With Quote Quick reply to this message  
Join Date: Apr 2008
Posts: 4
Reputation: priyankaa is an unknown quantity at this point 
Solved Threads: 0
priyankaa priyankaa is offline Offline
Newbie Poster

Re: how to display the message box in asp.net

 
0
  #4
Nov 18th, 2008
or u can assign string to label control and show the label control at top of ur web form.
Reply With Quote Quick reply to this message  
Reply

This thread is more than three months old.
Perhaps start a new thread instead?
Message:


Thread Tools Search this Thread



About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC