View Full Version : [CLOSED] FieldContainer hideLabel

May 02, 2014, 3:45 PM
Below is a window with a FieldContainer that has a TextField. For this sample each time the window is shown I would like to reassign the fieldlabels for the FieldContainer and TextField.

If you run it the way it is the UI looks correct with the underlying textfield label set to "Anything".

If you uncomment area #1 the underlying textfield label is set to "Details", but now the UI is showing the fieldlabel. Why is it shown when HideLabel is set to true in the defaults section?

If you uncomment area #2 the underlying textfield label is still set to "Details" and now the UI looks correct. Except in my real application an error is occurring because I have a combobox associated with a store in the fieldContainer.

<%@ Page Language="C#" %>

<%@ Register Assembly="Ext.Net" Namespace="Ext.Net" TagPrefix="ext" %>

<!DOCTYPE html>

<script runat="server">
protected void Submit(object sender, DirectEventArgs e)
X.Msg.Alert("Submit", string.Format("TBD")).Show();

protected void InitiateControls(object sender, DirectEventArgs e)
string description = DateTime.Now.ToString();

urGeneral_Purpose.FieldLabel = description;

// #1 - Uncomment line below the the field label appears for the text field.
//urGeneral_PurposeTFB.FieldLabel = "Details";

// #2 - Uncomment line below the the fieldlabel is rehidden for the text field.
// But it cause other issues if I have a combobox with a store in the fieldcontainer

protected void ResetDialog(object sender, DirectEventArgs e)

<head runat="server">
<title>FieldLabel Question</title>
<style type="text/css">
.indicator-UpperRight {
margin: -8px 0px 0px -6px;
<ext:ResourceManager runat="server" />
<ext:Window ID="NewRequest" runat="server" ClientIDMode="Static" Icon="User" Closable="false"
Title="User Request" Constrain="true" Width="680" Resizable="false"
BodyPadding="5" Border="false" Y="20" Layout="FitLayout" Modal="true" Hidden="true">
<ext:FormPanel runat="server" Region="Center" DefaultAnchor="100%" AutoScroll="true"
<ext:Hidden ID="hRequestCatId" runat="server" ClientIDMode="Static" />

<ext:FieldSet ID="fsGeneral" runat="server" Title="General" Collapsible="true" Hidden="false">
<ext:FieldContainer ID="urGeneral_Purpose" runat="server" FieldLabel="Purpose" Layout="HBoxLayout" AnchorHorizontal="100%" CombineErrors="true" MsgTarget="Qtip">
<ext:Parameter Name="HideLabel" Value="true" Mode="Raw" />
<ext:TextArea ID="urGeneral_PurposeTFB" runat="server" FieldLabel="Anything" AllowBlank="false" Flex="1" IndicatorIcon="BulletRed" IndicatorCls="indicator-UpperRight" MsgTarget="Qtip" />
<ext:Button runat="server" FormBind="true" Disabled="true" Text="Submit" Icon="BulletGo">
<Click OnEvent="Submit" />
<ext:Button runat="server" Text="Cancel" Icon="BulletCross" OnClientClick="App.NewRequest.close();" />
<BeforeShow OnEvent="InitiateControls" />

<ext:Button runat="server" Text="Open Window" OnClientClick="App.NewRequest.show();" />

May 05, 2014, 6:02 AM
Hi Chris,

The HideLabel option works initially only. It is ignored if a developer sets up a new FieldLabel. It is forced to appear.

For your scenario I can suggest the following:

urGeneral_PurposeTFB.Set("fieldLabel", "Details");

It sets the "fieldLabel" JavaScript property, but it doesn't show it.

May 06, 2014, 12:06 PM
Exactly what I needed. Thank you. Please close the thread.