[CLOSED] Still dont understand referencing Controls in Javascript: Select Handler and Button

  1. #1

    [CLOSED] Still dont understand referencing Controls in Javascript: Select Handler and Button

    Hey,
    I am still not getting it with the referencing of Controls in Handlers and Javascript.

    I have a ComboBox (inside a UserControl) and it has a Select Handler. I want that Select Handler to show a hidden button:

                            <Listeners>
                                <Select Handler="#{Field_Address_Icon}.setVisible(true)"/>
                            </Listeners>
    I have tried without the # too:

                            <Listeners>
                                <Select Handler="Field_Address_Icon.setVisible(true)"/>
                            </Listeners>
    The Button I am trying to access is placed inside thte same ColumnLayout:

    <ext:LayoutColumn ColumnWidth="0.04">
          <ext:Button ID="Field_Address_Icon" Icon="BulletTick" runat="server" StandOut="true" Visible="false"></ext:Button>
    </ext:LayoutColumn>
    I have also tried with different IDMode, "Explicit", "ExplicitClientID", "Ignore" to no avail. I just keep getting

    Uncaught ReferenceError: Field_Address_Icon is not defined
    Last edited by Daniil; Apr 04, 2011 at 9:00 AM. Reason: [CLOSED]
  2. #2
    Hi,

    #{Field_Address_Icon} should work if the ComboBox and the Button are placed in the same page.

    Do you use any IFrames?
  3. #3
    Hey,
    the Controls are all in the same Page, which happens to be an iFrame in another page but as far as there Controls go, they are all in the same Page (userControl).
  4. #4
    Hi,

    You set Visible=false for Field_Address_Icon. In this case, widget will not be rendered at all (will not be presented on client side)
    Please use Hidden instead Visible
  5. #5
    Ah, that did the trick indeed. Thx =)

Similar Threads

  1. Replies: 6
    Last Post: Aug 13, 2013, 5:59 AM
  2. [CLOSED] Referencing page controls in JavaScript objects
    By PLoch in forum 1.x Legacy Premium Help
    Replies: 8
    Last Post: Aug 16, 2011, 5:59 PM
  3. Replies: 14
    Last Post: Apr 12, 2011, 2:49 PM
  4. [CLOSED] [1.0] Referencing User Controls using #{}
    By bsnezw in forum 1.x Legacy Premium Help
    Replies: 2
    Last Post: Jan 15, 2010, 10:59 AM
  5. Controls Dont Dispaly Once Uploaded To Server
    By b.aytes in forum 1.x Help
    Replies: 8
    Last Post: Jul 29, 2009, 10:04 AM

Tags for this Thread

Posting Permissions