How to trigger a refresh of a dropdown list when the selection is changed

Hi,
This is a general ExtendScript question, but since I'm working with FM, I'll ask here first. I have a bit of a paradox here and I'm not sure of the best way to handle it.
I have a dialog box with a dropdown list, where I want to refresh certain controls when the user changes the selection in the list (dropdownList.onChange). This includes refreshing the contents of the list itself. However, the problem is, as soon as I try to refresh the list contents, it triggers onChange again. So, if I put the call to refresh the box within the onChange handler, it results in an endless loop, because my refresher function triggers onChange when it refreshes the list.
Does anyone know a better methodology, where I can safely trigger a refresh of a dropdown list within the list's own onChange event handler? I really wish that onChange was reserved for a user action only, or there was at least some property to that effect.
Russ

Hi Russ,
you can stop that with "stopPropagation()"
You can find this in "Javascript Tools Guide" on page 150.
I'm not able at the moment to send you an example 'cause I'm in a hospital for a while.
Happy New Year!

Similar Messages

  • How to stop a cluster constant typedef from resizing when the typedef is changed?

    Using LabVIEW 7.1...
    I've been using cluster typedefs to make make constants on the block diagram.  I usually resize them so they are nearly the size of a few characters.  When the typedef is updated the constant expands to full size.  Usually I can just resize it again but if the constant is inside a structure things get rather messy.  To stop the structures from resizing I've been leaving the constants outside of them.  Is there any way to stop the resizing?  I've ensured that autosize is set to None for both the typedef and the constant on the block diagram.

    I found the NI example that makes tst point.
    In the "Palette API" (that was developed by an NI Developer and recently posted to the LV Zone) shows how sub-VI's can be used to fix the "auto-explode" diagram issue.
    See image below.
    BTW: It also lets you document the data through the documention of the sub-VI.
    Ben
    Message Edited by Ben on 06-13-2007 03:12 PM
    Ben Rayner
    I am currently active on.. MainStream Preppers
    Rayner's Ridge is under construction
    Attachments:
    NI_Example.PNG ‏33 KB

  • How to find if all items in a list containing the selected color

    Hi
    I'm using the code below to check what color the user has selected. This is only working when my item got one color. Now I would like to change my code so each item can have one or more colors (seperated by semicolon). I guess
    I have to use string.IndexOf but I don't know how to use it in the .Where scentence below to return all the items that got the selected color.
    Thanks, Sigurd F
    var sampleDataGroups = await SampleDataSource.GetGroupsAsync();
    sampleDataGroups = sampleDataGroups.Where<SampleDataGroup>(Item => Item.Color == KeywordColorList.SelectedValue.ToString()).ToList();

    If the Color property of the SampleDataGroup class contains a string with different colours separated by a semicolon you could use the following code to determine whether the KeywordColorList.SelectedValue property is amont these colours:
    var sampleDataGroups = await SampleDataSource.GetGroupsAsync();
    sampleDataGroups = sampleDataGroups.Where<SampleDataGroup>(Item => Item.Color.Split(';').Contains(KeywordColorList.SelectedValue.ToString())).ToList();
    Compilable sample code:
    var sampleDataGroups = new List<SampleDataGroup>
    new SampleDataGroup { Color = "blue"},
    new SampleDataGroup { Color = "blue;red;green"},
    new SampleDataGroup { Color = "red;green"},
    string selectedValue = "blue";
    sampleDataGroups = sampleDataGroups.Where<SampleDataGroup>(Item => Item.Color.Split(';').Contains(selectedValue)).ToList();
    Please remember to close your threads by marking helpful posts as answer and then start a new thread if you have a new question. Please don't ask several questions in the same thread.

  • How to create a JSP dropdown list in the latest Early release

    Hello:
    this is probably an easy question. I am trying to create a dropdown list in a JSP form from a data control like "employee id". just dragging the data control attribute does not seem to have any effect in showing the drop down list when the JSP page is run.
    What is the missing factor?
    Thanks in advance for the help.

    Please ask this in the JHeadstart forum
    Timo

  • Dropdown list with multiple selections

    I need to create a dropdown list in a selection screen and allow the user to select more than one option. Can this be done. I know how to use VRM_SET_VALUES to create a dropdown but it restricts me to selecting only one value. The user should be able to select multiple values. Thank you.

    Hello,
    Try to use this Fm
    PARAMETERS :
    y_p_list TYPE char32  AS LISTBOX VISIBLE LENGTH 22
                                  MODIF ID rsg. .
    AT SELECTION-SCREEN ON VALUE-REQUEST FOR y_p_list.
      PERFORM y_f_dring_type_f4.
    FORM y_f_file_frmt_f4 .
      MOVE: text-212 TO y_wa_listbox1-field.
      APPEND y_wa_listbox1 TO y_i_listbox1.
      CLEAR y_wa_listbox1.
      MOVE  text-213 TO y_wa_listbox1-field.
      APPEND y_wa_listbox1 TO y_i_listbox1.
      CLEAR y_wa_listbox1.
      MOVE  text-214 TO y_wa_listbox1-field.
      APPEND y_wa_listbox1 TO y_i_listbox1.
      CLEAR y_wa_listbox1.
      MOVE  text-215 TO y_wa_listbox1-field.
      APPEND y_wa_listbox1 TO y_i_listbox1.
      CLEAR y_wa_listbox1.
      CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
        EXPORTING
          retfield        = 'FIELD'
          dynpprog        = sy-repid
          stepl           = 1
          value           = ' '
          value_org       = 'S'
          display         = ' '
        TABLES
          value_tab       = y_i_listbox1[]
        EXCEPTIONS
          parameter_error = 1
          no_values_found = 2
          OTHERS          = 3.
      IF sy-subrc <> 0.
      ENDIF.
      REFRESH y_i_listbox1.
    ENDFORM.                    " y_f_file_frmt_f4
    Use this code you will get the List box in selection screen.

  • Is it possible to create the ALV output with dropdown list for the columns

    Hi forum experts,
                              Could the ALV output contain the dropdown list for the column names? if yes, then how we can acheive this to happen.
    Thanks in advance,
    Regards,
    Samad.
    Edited by: Samad arif on Aug 21, 2009 4:40 PM

    Hi Arif,
    Yes we can .FOr the codding check the article,
    [dropdowns in ALV|https://wiki.sdn.sap.com/wiki/display/Snippets/DropdownsinALV]
    regards,
    Archana
    Edited by: Archana Kumari on Aug 21, 2009 1:22 PM

  • Prepopulate dropdown list based on selections made in other fields

    I wonder if anyone can help?
    A form with a radio button group containing two radio buttons "yes" and "no".
    Below the radio buttons is a dropdown list that has three items in the list "option A, option B, & option C.
    Below that, is another dropdown list, with three items, "10000", "15000" & "20000"
    How can I do the following?
    When radio button "yes" is selected, and dropdown list "option A is selected, it prepopulates "10000" in the bottom dropdown list
    When radio button "yes" is selected, and dropdown list "option B is  selected, it prepopulates "15000" in the bottom dropdown list
    When radio button "yes" is selected, and dropdown list "option C is  selected, it prepopulates "20000" in the bottom dropdown list
    Thanks in advance!

    Hi $Nith$
    Just sent you a PM

  • Headers in Dropdown lists? (Non-selectable items)

    Does any one know how to make headers in dropdown lists? I have 2 groups of items I want to add a header for each in the dropdown list. The headers just have to be non selectable.
    thanks,

    Hi Kris,
    In Designer 7.1, I created a DropDown List which includes Headers and sub categories under these headers, where the Headers are not selectable. When I built my DropDownList I then assigned Values to each item in the list, which I've put in brackets for you:
    HEADER ONE (10)
    Item A (1)
    Item B (2)
    Item C (3)
    HEADER TWO (11)
    Item X (4)
    Item Y (5)
    Item Z (6)
    This is the JavaScript I wrote on the Exit event:
    if (DropDownList.rawValue > 10) {
    DropDownList.rawValue = "";
    Hopes this works for you.

  • HT201272 How do I download previously purchased albums from iTunes when the album has either disappeared from my computer or the tunes are not playable?  The album shows as purchased on the iTunes store, but not available to download to my authorized devi

    How do I download previously purchased albums from iTunes when the album has either disappeared from my computer or the tunes are not playable?  The albums show as purchased on the iTunes store, but not available to download to my authorized device.  I also have albums that appear in my library, but are not able to be added to my iPod from my computer

    When you download something from the iCloud, it is a brand new licensed copy. Your iCloud account just contains a notation that you have this app. It isn't storing an actual copy of the app from your Mac.

  • I don't know of there is anyone than can fix this age old Apple problem.   Does anyone know how to retrieve things under an old Apple ID when the email used for that account no longer exists? I am trying to update a number of apps that was bought under an

    I don't know of there is anyone than can fix this age old Apple problem.   Does anyone know how to retrieve apps under an old Apple ID when the email used for that account no longer exists &amp; I can't remember the password? After speaking with Apple Acct. Security, I got the security Q right but my birthday was wrong! They wanted the serial number from my phone that was 3 iPhones ago! Seriously??!!
    Any updated way to work around this? No Apple people can correct it.
    Thanks,
    Joe

    You need to ask Apple to reset your security questions. To do this, click here and pick a method; if that page doesn't list one for your country or you're unable to call, fill out and submit this form.
    (122986)

  • How can I log onto iCloud from my iPad when the option is in grey and therefore not available

    How can I log onto iCloud from my iPad when the option is in grey and therefore not available. I deleted my account as it was showing up with an old Id ( I'd changed my email) but now I've done that it won't give me the option of logging back on. Do I have to do this on another device Or computer linked to iTunes first?
    THanks

    Hi Kate, have you perchance enabled restrictions on your device. (Settings > General > Restrictions)

  • How can I prevent that emails are downloaded (POP3) when the lid of my MacBook Pro is closed?

    How can I prevent that emails are downloaded (POP3) when the lid of my MacBook Pro is closed?

    Disable Power Nap in the Energy Saver pane of System Preferences. Uncheck the box marked Enable Power Nap... in each of the tabs.

  • How to Add a parameter of currency exchange rate in the selection screen

    Dear Friends,
    How to Add a parameter of currency exchange rate in the selection screen with format (9999.99999). wich field i need to take.
    Thanks,
    Sridhar

    TCURR-UKURS.
    ~Suresh

  • How to find the when the password is changed for a system User

    Hi to all,
    We have a test database where our application connects to system user. The application runs more than a month without any issues, But suddenly my system and sys password gets changed. I wonder how this would happen. I have checked with DBA_USERS to check whether the account gets locked, But the account is in the Open state.
    I need to find out when the password gets changed for these users and who changed it? Is there any possible to trace it or we need to enable the auditing to find it in future.
    Kindly let me know the possible ways.
    Regards,
    Vijayaraghavan K

    Vijayaraghavan Krishnan wrote:
    Hi to all,
    We have a test database where our application connects to system user. The application runs more than a month without any issues, But suddenly my system and sys password gets changed. I wonder how this would happen. I have checked with DBA_USERS to check whether the account gets locked, But the account is in the Open state.
    I need to find out when the password gets changed for these users and who changed it? Is there any possible to trace it or we need to enable the auditing to find it in future.
    Kindly let me know the possible ways.
    Regards,
    Vijayaraghavan KThe only way to implement an Oracle Audit

  • How do I invoke an ActionListener on a page when the page initially loads?

    How do I invoke an ActionListener on a page when the page initially loads?
    Page 1: A user clicks on a h:commandButton and is navigated to Page 2.
    Page 2: When the page loads and goes through RESTORE_VIEW, APPLY_REQUESTS and RENDER_RESPONSE, I need to call an ActionListener in the managed bean for Page 2.
    However, if the user comes in from any other page than Page 1, the ActionListener cannot be invoked intially when the page loads. The user has a choice to click on the h:commandButton on Page2 to invoke the ActionListener.
    What is an example of invoking a method with the ActionListener signature in Java code?
    Where would I put the code to invoke the ActionListener, in a beforePhase or afterPhase, constructor?
    Thanks,
    --Todd                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

    Interesting. You're right. It doesn't happen when I click away from this site and then return. Maybe I'm barking up the wrong tree. Maybe it's the specific website I was thinking of and not Firefox. Unfortunately, I have to use that site all the time for work. I'll try contacting their webmaster. Thanks for your help.

Maybe you are looking for

  • How do i change the default itunes account on my mac book?

    i got my wife a new mac book for our anniversary, and i got the old one, but i cannot set my itunes account to be the default, in order to access my account i have to plug in my ipod, i'm sure it's an easy fix, i just can't figure it out

  • How to Clear Application Data on Macbook Pro?

    When I checked how much storage space I have on my mac, it shows that I have 99.3 GB of Applications. I checked the few applications I have in my Applications folder, and I'm positive it doesn't add up to 99 GB. How do i clear up this excess data?

  • [JS CS3] RegExp Object containing only one backslash (how to escape)

    Hi I'm trying to escape one backslash in my RegExp Object, but I get a Syntax Error:      myObj = new RegExp ( "\\" ); I tried it phyton Style   myObj = new RegExp ( "\\\\" ); but that's not working right. Thanks for any hint. Stefan

  • How to modify the email remittance template

    Hello, We have a requirement on modifying the email remittance template. We are looking to add a new fields in the remittance detail section. How do we do this?.  Any inputs are highly appreciated. Thanks, Sushma

  • Permissions repair/ disk utility

    Hello: I believe I have a permissions repair problem as but I'm not entirely sure. I'm very untechnical and somewhat shakey on my conclusions and how to proceed. My computer slowed down this week after downloading freeware. I dumped all but one progr