Click here to Skip to main content
Rate this: bad
good
Please Sign up or sign in to vote.
See more: .NET
Good Afternoon to all,
 
In my project i have a requirement when i click on the create button it will diplay a confirmation box like "u want create" if i click on yes tha data will be saved into database,otherwise it will be not saved in database.i used javascript and got but i have problem with that i clicked even no button also it will saved in database,so pls help me how to display confirmation box and after clicking yes only the data will be saved into database?
 

Thanks in advance.......
Posted 1-Oct-12 0:29am
Edited 1-Oct-12 0:30am
v2
Comments
Abhijit Parab at 1-Oct-12 5:32am
   
what code you have used for that? please mention here.
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 2

confirmation box with yes no
For this, you would need VBScript confirm instead of Javascript. Javascript gives, Ok & Cancel as options whereas VBScript will give you Yes & No.
Please find the link below that has all the options and will help you out: Alerts, Confirms and Prompts [^]
 
OR
 
you can try jQuery modal-dialog or UI-confirm-dialog and configure it for yes-no option.
Refer:
How to Create a jQuery Confirm Dialog Replacement[^]
ASP.NET jQuery UI confirm dialog [^]
ASP.NET JQuery Confirm Dialog[^]
 
OR
 
you can use Ajax ModalPopupExtender for it.
Refer: ASP.NET confirmation box with yes/no button options using modalpopup[^]
 
..and more similar QA on CP Search[^]
  Permalink  
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 4

u didn't mentioned in which language u r working..

just go through this link..hope u will get the solution

http://forums.asp.net/p/1659272/4327213.aspx/1?Re+Need+to+show+confirm+box+before+inserting+data+in+database[^]
  Permalink  

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 George Jonsson 175
1 Kornfeld Eliyahu Peter 169
2 Zoltán Zörgő 139
3 PIEBALDconsult 130
4 OriginalGriff 120
0 OriginalGriff 6,165
1 DamithSL 4,658
2 Maciej Los 4,107
3 Kornfeld Eliyahu Peter 3,649
4 Sergey Alexandrovich Kryukov 3,342


Advertise | Privacy | Mobile
Web02 | 2.8.141220.1 | Last Updated 1 Oct 2012
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100