C# Tutorials and offshore development in India
    Tutorials   Resources   Forum   Reviews   Communities   Interview   Jobs   Projects   Training   Your Ad Here    
Silverlight Games | Mentor | Code Converter | Articles | Code Factory | Computer Jokes | Members | Peer Appraisal | IT Companies | Bookmarks | Polls | Revenue Sharing | Lobby | Gift Shop |


Prizes & Awards
My Profile



Active Members
TodayLast 7 Days more...






Resources » Articles » ASP.NET/Web Applications »

Pop-Up Boxes in JavaScript


Posted Date: 31 Oct 2008    Resource Type: Articles    Category: ASP.NET/Web Applications
Author: Pradeep IyerMember Level: Diamond    
Rating: 1 out of 5Points: 5



There are three types of pop-up boxes in the JavaScript. They are:

1. alert()
2. confirm()
3. prompt()

alert()
********

It is used to alert the user with some message. It contains a. "Ok" button on it.

Syntax: alert(mesg);
Example: alert("Hello");

confirm()
***********

It is used to confrim something from the user. It contains both the "Ok" button and the "Cancel" button on it.

Syntax: confrim(mesg);
Example: cofirm("Do you want to exit?");

prompt()
**********

It is used to prompt the user to enter some text. It contains a textbox, an "Ok" button and a "Cancel" button on it.

Syntax: prompt(mesg,default_value);
Exmple: prompt("Enter a number","defaultnumber");

Here the default_value is the text displayed on the texbox by default.
promt() returns the value or text entered by the user if the user clicks "Ok", otherwise it returns a null.



REGARDS
PRADEEP Y




Responses


No responses found. Be the first to respond and make money from revenue sharing program.

Feedbacks      
Popular Tags   What are tags ?   Search Tags  
Sign In to add tags.
(No tags found.)

Post Feedback


This is a strictly moderated forum. Only approved messages will appear in the site. Please use 'Spell Check' in Google toolbar before you submit.
You must Sign In to post a response.
Next Resource: How to send SMTP mail in ASP.NET using C# technology.
Previous Resource: Screen Scraping
Return to Discussion Resource Index
Post New Resource
Category: ASP.NET/Web Applications


Post resources and earn money!
 
Related Resources



dotNet Slackers

About Us    Contact Us    Privacy Policy    Terms Of Use