Ismail
Registered:1337950661 Posts: 87
Posted 1405494575
Reply with quote
#1
Hi I would like to know how could i add a popup message to ask Are you sure you would like to save this data and two buttons Ok and Cancel? This action needs to happen when they push a save button I am using Vb.net
__________________ Ismail
denver_searle
Registered:1325667462 Posts: 6
Posted 1405497546
Reply with quote
#2
Hi Ismail Simply add the following javascript to your Save buttons "OnClientClick" property:return confirm("Are you sure you want to save?");
Ismail
Registered:1337950661 Posts: 87
Posted 1405498086
Reply with quote
#3
Thank you
__________________ Ismail
JimiJ
MVP Developer
Registered:1112254853 Posts: 1,962
Posted 1405508143
Reply with quote
#4
__________________ Jaime Jegonia
Iron Speed MVP Developer ". . . and whoever sows generously will also reap generously" 2 Cor 9:6
denver_searle
Registered:1325667462 Posts: 6
Posted 1405512148
Reply with quote
#5
That's what i like about developing, there's always more than one way to do something ... know how about a central place to add the confirmation to all Save buttons
porphi
Registered:1126097590 Posts: 648
Posted 1405516174
Reply with quote
#6
If you’re referring to an ISD theme button then in the shared folder find the file ThemeButton.ascx.(vb/cs) and register a prerender event. In the prerender event check the text value of the button and if it’s save or save and new add an onclick attribute for the confirm.
You could also do something similar in the base application record control iterating over the form collection looking for controls of the type IThemeButton then set the onclick event there.
I could think of a few more places but these should give you an idea of where to start.
__________________ Thank you, Phil Porter PPG&A, INC. pporter@ppgainc.comhttp://www.ppgainc.com https://rapidsprout.com 678-362-2035
JBEMETO
Registered:1278716579 Posts: 168
Posted 1484113708
Reply with quote
#7
Hello Folks, Was there a central way to disquiet the save process ? For a large project too many save button will go on quietly without many effect. Thanks
__________________ JBEMETO
JimiJ
MVP Developer
Registered:1112254853 Posts: 1,962
Posted 1484269446
Reply with quote
#8
For all Delete buttons, confirmation is automatic through the wizard. However, doing it in all Add buttons could be counter productive, unless on special cases. Jimi J
__________________ Jaime Jegonia
Iron Speed MVP Developer ". . . and whoever sows generously will also reap generously" 2 Cor 9:6
aa0708198
Registered:1417590485 Posts: 11
Posted 1484719863
Reply with quote
#9
Hi, How do show a custom message if the text was enter in the numeric field "Please enter a mobile number.". Regards,
__________________ AK
JimiJ
MVP Developer
Registered:1112254853 Posts: 1,962
Posted 1484803712
Reply with quote
#10
You can use Mobile Number validation (google it) and pop a message if invalid. Mobile number masking is also a good alternative. Cheers, Jimi J
__________________ Jaime Jegonia
Iron Speed MVP Developer ". . . and whoever sows generously will also reap generously" 2 Cor 9:6