Combobox not showing displayField values

  1. #1

    Combobox not showing displayField values

    I'm having an issue showing data in my combobox. It loads the data but doesn't display the displayField value for selecting. Instead I just see the correct number of lines as 2 pixel high blanks when I drop the combobox down. Any help would be appreciated.

    <ext-comboBox fieldLabel="Org" labelWidth="50" padding="3" displayField="Name" valueField="Id">
        <listeners>
            <select handler="alert('hello world');" />
        </listeners>
        <store>
            <ext-store autoLoad="true">
                <proxy>
                    <ext-ajaxProxy url="@Url.Action("GetOrgs", "Header")"/>
                </proxy>
                <fields>
                    <ext-integerDataField name="Id" />
                    <ext-stringDataField name="Name" />
                </fields>
            </ext-store>
        </store>
    </ext-comboBox>
  2. #2

    Solved but not sure why

    The fix was to simply change displayField from "Name" to "name".

    Anyone know why this works, and why "Name" wouldn't work?
  3. #3
    I think it's a problem of converting field names into properties of classes managed in JavaScript, which have a naming convention that forces you to have a lowercase initial.
    I confirm that I have always treated the fields with the initial lowercase to avoid the problem you reported.

Similar Threads

  1. Replies: 5
    Last Post: Mar 13, 2015, 10:19 AM
  2. [CLOSED] ComboBox added values are not showing.
    By rnachman in forum 1.x Legacy Premium Help
    Replies: 2
    Last Post: Mar 29, 2013, 12:45 PM
  3. Replies: 7
    Last Post: Feb 27, 2013, 12:28 PM
  4. Replies: 2
    Last Post: Mar 03, 2012, 3:33 PM
  5. Replies: 2
    Last Post: Jul 28, 2010, 6:50 AM

Tags for this Thread

Posting Permissions