I am trying to a add a TextField. I am using
EditField _textBox = new EditField("Subject", "Some text"); for creating a textbox with label as Subject. I want to change the color of only the label(Subject) of the textbox.
Change color of only the label for TextField in Blackberry
775 Views Asked by chaitu2408 At
3
You're going to need a custom field to do this because it is not possible to change the colour of the
EditField's label, even if you overrideEditField.paint().My suggestion is:
CustomEditField) which extendsHorizontalFieldManagerLabelFieldfor the label and anEditFieldfor the editable textHere's the code:
Of course, you're still going to need to add in your methods to set and get the text from your EditField, and any other specific methods which you need from EditField, but as a proof of concept this works.