File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Confirm Button

 
sachin shinde
Greenhorn
Posts: 27
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi friends!
I want to know for confirm message Box what actually it returns when we pressed "ok" and "cancle"
How to check it?
Pl reply
sachin
 
Eric Pascarello
author
Rancher
Posts: 15385
6
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I tried to explain it here,
<script>
function confirm_alert()
{
input_box=confirm("Click OK or Cancel to Continue");
if (input_box==true)
{
// Output/Function when OK is clicked
alert ("You clicked OK");
}
else
{
// Output/Function when Cancel is clicked
alert ("You clicked cancel");
}
}
</script>
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic