I have a question about DataSourceTextFields.
Is there a method to hide the title of a DataSourceTextField like the setShowTitle method for the FormItem?
I have a question about DataSourceTextFields.
Is there a method to hide the title of a DataSourceTextField like the setShowTitle method for the FormItem?
If you don’t want a header label to show for a field, simply set the title of that field in the corresponding ListGridField to “”. The display attributes of the final grid are a merge of the DataSourceField ( which provide the defaults ), and the ListGridField (which overwrites any required display attributes)
See the source for this sample.
Sanjiv
I’m not using a ListFieldGrid, but instead im using the DataSourceTextFields much like in this example:
http://www.smartclient.com/smartgwt/showcase/#layout_form_databinding
If i try to set the title to “” it still shows the “:”…
See the *titleSuffix and *titlePrefix properties on DynamicForm - that’s where the colon is from.
A blank title works for a Grid. showTitle:false works for form fields, but make sure you realize this has layout consequences (eg a TextItem will take up one column, not two). See the FormLayout overview from the SmartClient Reference for details.