-
8 Feb 2012 8:10 PM #1
Unanswered: how to remove Done button in Select field in snecha touch
Unanswered: how to remove Done button in Select field in snecha touch
I want to remove the done button from selectfield .When i select and oprion from select field then it should dispaly in select field. Please provide me any solution
-
9 Feb 2012 11:12 AM #2Sencha - Senior Forum Manager
- Join Date
- Mar 2007
- Location
- St. Louis, MO
- Posts
- 33,714
- Vote Rating
- 438
- Answers
- 3113
You would need to override the getPicker method on the Select field and add add the config doneButton : false to the Ext.Picker
Mitchell Simoens @SenchaMitch
Sencha Inc, Senior Forum Manager
________________
http://www.JSONPLint.com - Source to lint your JSONP!
Check out my GitHub, lots of nice things for Ext JS 4 and Sencha Touch 2
https://github.com/mitchellsimoens
Think my support is good? Get more personalized support via a support subscription. https://www.sencha.com/store/
Need more help with your app? Hire Sencha Services services@sencha.com
Want to learn Sencha Touch 2? Check out Sencha Touch in Action that is almost in print!
When posting code, please use BBCode's CODE tags.
-
9 Feb 2012 6:55 PM #3
Attachin code please let me know it ti correct
Attachin code please let me know it ti correct
HI ,
I am attaching my code . please let me it is correct way to remove that done button. i want when i click on any display value in select field that should dispaly in select field
Code:{ xtype : 'selectfield', name : 'selectcompany', placeHolder : 'Select Company', width : '95%', id : 'selectcompany', value:'', valueField : 'idcompany', displayField : 'companyname', store:companyStoreName, getPicker: function() { if (!this.picker) { this.picker = new Ext.Picker({ slots: [{ align : 'center', name : this.name, valueField : this.valueField, displayField: this.displayField, value : this.getValue(), store : this.store }], listeners: { change: this.onPickerChange, scope: this }, doneButton: false; }); } return this.picker; } }Last edited by mitchellsimoens; 10 Feb 2012 at 4:04 AM. Reason: added [CODE] tags
-
10 Feb 2012 4:05 AM #4Sencha - Senior Forum Manager
- Join Date
- Mar 2007
- Location
- St. Louis, MO
- Posts
- 33,714
- Vote Rating
- 438
- Answers
- 3113
Should work. Have you tried it?
Mitchell Simoens @SenchaMitch
Sencha Inc, Senior Forum Manager
________________
http://www.JSONPLint.com - Source to lint your JSONP!
Check out my GitHub, lots of nice things for Ext JS 4 and Sencha Touch 2
https://github.com/mitchellsimoens
Think my support is good? Get more personalized support via a support subscription. https://www.sencha.com/store/
Need more help with your app? Hire Sencha Services services@sencha.com
Want to learn Sencha Touch 2? Check out Sencha Touch in Action that is almost in print!
When posting code, please use BBCode's CODE tags.
-
10 Feb 2012 7:44 AM #5
Button removed but how the value will select
Button removed but how the value will select
Button has removed but values are not selected how it will work
Using follwoing code
{
xtype : 'selectfield',
name : 'selectcompany',
placeHolder : 'Select Company',
width : '95%',
id : 'selectcompany',
value:'',
valueField : 'idcompany',
displayField : 'companyname',
store:companyStoreName,
getPicker: function() {
if (!this.picker) {
this.picker = new Ext.Picker({
slots: [{
align : 'center',
name : this.name,
valueField : this.valueField,
displayField: this.displayField,
value : this.getValue(),
store : this.store
}],
listeners: {
change: this.onPickerChange,
scope: this
},
doneButton: false,
cancelButton:false
});
}
return this.picker;
},
onPickerChange : function(picker, value) {
alert(value)
this.setValue(value);
this.fireEvent('change', this, this.getValue());
}
},
-
2 Sep 2012 4:09 PM #6
same problem
same problem
Hi,
I am facing the same problem.
Can you please share how you solved it.
-
13 Sep 2012 3:37 AM #7
How to change color of Done and Cancel button of select Field
How to change color of Done and Cancel button of select Field
// Hi i am using sencha touch 2.0 framework . I used select field in my project the thing is that i need to change the color of done and cancel button of the select field. But those picker buttons are not visible in browser but appearing in device. So how can i apply color to those two buttons.
-
13 Sep 2012 2:52 PM #8
I did by giving config options to done and select button just like normal button and gave css property to it.
and in css fileCode:doneButton:{ text:'Fertig', cls: 'pickerdonebutton' },
Code:.pickerdonebutton { background:#125f9b !important; color:#ffffff !important; }


Reply With Quote