1.最普通的提示框
Ext.MessageBox.show({
title: '警告',
msg: '请选择一条记录',
icon: Ext.MessageBox.WARNING,
buttons: Ext.Msg.OK
});
或者
Ext.Msg.alert('Status', 'Changes saved successfully.');
2.带确认的提示框
Ext.MessageBox.confirm('提示', "确定?", function (btn) {
if (btn == "yes") {
//TODO
}
});
3.带输入框的提示框
Ext.Msg.prompt('Name', 'Please enter your name:', function(btn, text){
if (btn == 'ok'){
// process text value and close...
}
});