PDA

View Full Version : [DUPLICATE] How to set field label when the form panel is already rendered



zaccret
16 Jun 2008, 3:41 AM
Hi,

Does anyone know how I could change a field label when the form panel is already rendered ? setFieldLabel(String) has no effect.

zaccret
19 Jun 2008, 1:12 AM
http://extjs.com/forum/showthread.php?t=38066

gslender
19 Jun 2008, 1:28 AM
...as Darrell explained, there really is not currently a simple way to do this :(

Why? if you look at the source of FormLayout you will see that the field label is created as part of the template and constructed with the label embeded - look at line 123 the label is item {1} whereby it is inserted into the string at runtime when the form is created.

Darrell would need to refactor the label field to be a distinguishable element in the DOM - its currently not...

sorry...