View Full Version : confirm with ok - cancel buttons

11 Nov 2009, 5:01 PM
just wondering how can I change a confirm dialog so that the button are ok and cancel
vs. yes and no.

Ext.MessageBox.confirm('title', 'message',function(s){

looks like I need to define a messagebox vs. using the shorthand confirm.

11 Nov 2009, 5:07 PM
Confirm is just a shortcut for calling show(), so you can call that and pass in the appropriate options.

11 Nov 2009, 5:38 PM
Just to expand on that answer with an example...

title:'Do Something',
msg: 'Ok or Cancel?',
buttons: {yes: 'Ok', no: 'Cancel'}, // or Ext.Msg.OKCANCEL
fn: Ext.emptyFn

21 Mar 2013, 4:35 AM

Is there anybody implemented shortcut keys for message box yes, no cancle. like alt+y, alt+n, alt+c. I am having a requirement to achive the same. so any body implemented this feature, please share ur idea.

Thanks in advance

Gunasekar Jabbala