Restrict the user to select a fixed number of values only to the SelectManyShuttle component

Hello

I'm working on JDeveloper 11.1.1.7.

My requirement is to allow the user to select a fixed number of values using the SelectManyShuttle component only.

Suppose if I have 10 available values in the left part of the element of the shuttle, I should allow the user to shuttle only three values on the right.

In the image below, I already have 3 employees. Now the user should not be able to select employees more.

< af:selectManyShuttle label = "Label 1" id = 'sms1.

value = "#{pageFlowScope.shuttleBean.selectedEmpNames} '"

leadingHeader = "all employees".

trailingHeader = "selected employees.

simple = "true" >

< f: selectItems value = "#{pageFlowScope.shuttleBean.allEmpNames} '"

ID = "si1" / >

< / af:selectManyShuttle >

Shuttle.png

Can you please share your ideas to achieve this?

Respect,

Vinod

There are different strategies how to implement this. The easiest will be to check the size of the selected list when the user cklicks the button finished. If the number is larger that the size limit display you an error message.

Another way would be to use a valueChangeListener and the listener, check the size of the new value and add the tonthe size from the size of the already selected list. Then display an error message.

Timo

Tags: Java

Similar Questions

  • How to use JavaScript to limit the number of boxes to check the user can select a PDF form?

    How to use JavaScript to limit the number of boxes to check the user can select a PDF form?

    Here's the working solution

    Please rename all the boxes like chkBox0, chkBox1... .chkBox30 (must start with 0)

    Value of exports of each checkbox must be "Yes" (default value is Yes)

    Place this Code at the level of the Javascript Document

    -Code JavaScript document-

    var counter = 0;                Checked the meter

    -Count boxes checked again when the document is closed and reopened.

    for (var i = 0; i)<= 30;="">

    If (getField("chkBox"_+_i).value == 'Yes') {}

    Counter += 1;

    }

    }

    -The function of validation-

    function validateCheckBox(name,value) {}

    If (value == 'Yes' & meter)<>

    Counter += 1;

    } else if (value == 'Off') {}

    counter = 1;

    } else {}

    getField ("name") .value = "Off";

    App.Alert ("you can select only four checkboxes");

    }

    }

    -End of Document Javascript-

    Now put this line in the MouseUp event all checkboxes

    Box - Code MouseUp event.

    validateCheckBox (event.target.name, event.target.value);

    //----------------------------------------------------------------------------------

    Hope this will help

    Kind regards

    Post edited by: Mohammad Irfan

  • Show/hide fields based on the user's selection

    I know little of Javascript, but my first attempts to integrate it in Acrobat are bothersome. I have created a simple form where the user via a check box the number of people that he or she must register, then the form shows that several fields to complete. I tried to make it work with a single field, before I add more.

    In this example, I'm trying just to get the second hidden registered field if the user checks only 1 person to register. (I already know that I have issues when it comes to hide several fields).

    If (event.target.value == "0") {}

    this.getField("Registrant2").display = display.hide;

    }

    Given that I do not know what is the value of exports, try this:

    If (event.target.value! == 'Off') {}

    this.getField("Registrant2").display = display.hidden;

    }

    You can add an else clause so that the field is displayed when the check box is not selected:

    If (event.target.value! == 'Off') {}

    this.getField("Registrant2").display = display.hidden;

    } else {}

    this.getField("Registrant2").display = display.visible;

    }

    If this does ' t work, you don't maybe not the correct domain name. Verify that the console (Ctrl + J) to see all JavaScript errors are reported.

  • I want to restrict a user to enter in the same interval of time or with in the same interval

    Hi all

    I am pleased to wish you a happy and prosperous new year.

    Q: in my application I need to provide a validation the user to not enter the same interval of time or in the same interval of time

    To make a unique combination of the user and the time interval that I can use a Unique Index and then I can get the unique combination of the intervals of this user. But I want to restrict the user even not to enter with in the same time interval.

    Scenario: Let's assume we have 10 records of 10 different users with different time intervals, one of them

    syam user with time interval entry 10:00 to 12:30, then the following entry syam user of time intervals should not be 10:00 to 12:30 and should not be in the same interval from 10:00 to 11:30 or 11:00 to 12: 10.

    How can I do this, I need to provide a validation.

    Thanks in advance

    -I borrowed the table of Bruno

    INSERT INTO MaTable VALUES ('tom', TO_DATE ('0701151330', 'DDMMYYHH24MI'), TO_DATE ('0701151740', 'DDMMYYHH24MI'));
    COMMIT;

    CREATE MATERIALIZED VIEW LOG ON mytable WITH SEQUENCE, ROWID, PRIMARY KEY including the NEW VALUES;

    Create materialized view mv_overlap_chk
    cool off quickly on commit WITH ROWID
    as
    Select t1.rowid rid1, t2.rowid rid2
    FROM MaTable t1
    mytable t2
    where t1.usr = t2.usr
    AND t1.rowid<>t2.rowid
    AND (t1.from_dte BETWEEN t2.from_dte AND t2.to_dte
    OR t2.from_dte BETWEEN t1.from_dte AND t1.to_dte
    )
    /

    ALTER TABLE mv_overlap_chk add CONSTRAINT CHK_OVERLAP CHECK(1=0);

    -trial:

    INSERT INTO MaTable VALUES ('tom', TO_DATE ('070120151630', 'DDMMYYYYHH24MI'), TO_DATE ('070120151840', 'DDMMYYYYHH24MI'));

    1 line of creation.

    SQL > commit;
    Commit
    *
    ERROR on line 1:
    ORA-12008: error path refresh materialized view
    ORA-02290: check constraint (JSU. CHK_OVERLAP) violated

    Therefore, constraint will be checked on commit.

  • Advanced Action help - the user must select all before moving on to the next slide

    I need a tip action that will require the user to select a number of option buttons containing information until the next button appears. I don't know how to write it. I want the user to be able to select each button in any order that they choose. Can someone give me a step by step process? Your help is greatly appreciated!

    What version do you use? Why radio buttons? The behavior expected normal of radio buttons is that only one can be selected, you seem to ignore what is generally accepted. As having a next button appears only after several items have been selected, this has been explained many times in this forum and have many examples in my blog. They are free, maybe not considered worth nothing...

    You need a variable associated with each item. Click on an item to trigger a conditional action advanced or shared with two decisions. First decision is simulated standard action, rotate the variable from 0 to 1, then is a real condition that will make the next visible button if all variables have the value 1.

  • Select the desire to only one display limited the number of values

    Hi guys,.

    I have a choice of a select on my page I need to display a list of reports. There should be no restriction on the number of reports that can be created, and therefore, there should be no restrictions on the number shown in the choice of a select.

    However, when the choice of a select 25 values in it, no more will appear later. I have to delete the old values for the most recent to be displayed I don't want.

    Is there a way to make the choice hold a selection of more than 25 values?

    Thank you
    -Mark

    Mark,

    Have you gone into the definition of the page and changed the size of the range for the iterator-1?

    John

  • Why 'Read a fixed number of samples' help with the error 200279?

    Hello world

    It is a question about a tip found in the explanations on the acquisition of data error-200279. This explanation it is said: '... ". reading a fixed number of samples instead of all available samples can fix this... »

    AFAIK the DAQ system buffer is a ring buffer, so we can consider having a writing position and a position of reading "in motion" along the ring. While the playback position is the position of writing, everything is brilliant. But if writing catch up reading, samples will be overwritten and therefore-> error-200279.

    So here's my question:

    I do not understand why a fixed amount of reading samples would help me with this error. I don't understand why other Councils (increase in the size of the buffer or the frequency of reading) would help me because they reduce the probability of the playback position being outrunned by the position of the writing.

    But if I read everything which is available, whenever I read the only way for the buffer fills would be that the time between two readings take more time than necessary fill the entire buffer.

    Or in other words to each reading I will read at least as many elements that it has been filled by writing since the last read, so the only way to fill the buffer would fill completely at once since the last reading.

    This should be a lot safer than reading a fixed amount, because in this case, I'd get a problem if I read it that fewer items than writing complete at the same time, regardless of the number of items that would be and no matter what the size of the size of the buffer that would be.

    What I understand here?

    Thanks and regards,

    Sebastian

    SBach wrote: this VI is a State Machine in queue, the reading part is made in the case of timeout and cases are used as initialization orders, stop and change the outside DAQ hardware.

    That I can't tell when these commands will trigger the time between two readings could not be set. If a strictly fixed amount of data could lead to a buffer to fill.

    Init command: you certainly don't have a running task.

    Stop: You stop the task, then doing here if you get overrun.

    Edit tasks: you will probably need to stop the task still before you can edit the task, but let's go back to not caring.

    The way I see it, the other commands must stop the task anyway.  If you can leave the timeout do its job and do not do a lot of extra stuff.

    And here are some alternatives:

    1. use a shift register to keep track of how long your wait time should be.  In the case of reading, make the deadline to be whatever it is that you are using.  In all other cases, only the 0 so that a read timeout must be performed immediately (once the queue is empty).

    2. When you do your check to 1.5 times the timeout, if there is too much data, queue a reading at the front of the queue so that playback will happen.  The idea is that you really want to keep the same stack sizes to keep the memory to be allocated.  So just to be read more often.

  • Wait for the user to select the OK button

    For my application, I can't use a simple MessagePopup where the user must select the OK button to continue.

    I created a new Panel with just a text message and an OK button to act as a MessagePopup.

    When I call InstallPopup and the box pops up that I have to wait until the user selects OK before continuing as the MessagePopup.

    How can I accomplish this?

    Thank you!

    John W.

    The popup has no effect on the mouse: it can happen that you have a function that manipulates the cursor before the popup is displayed? A SetWaitCursor (1); would be sufficient.

  • Asking the user to select a file path to record data to

    Hello

    To improve the 'user interface', and the usability of my VI, I would like to have the dialog box "select file path" appears automatically, rather than create a user by clicking on an icon on the front panel to display the path of the file dialog. The 'order' of operations would be as follows:

    VI implementing--> Dialogue request to the user the name of the file--> VI adds automatically it appropriate extension--> traditional dialog windows 'save file' opens to allow the user to select the appropriate folder to save the file in--> rest of VI runs.

    I have everything other works independently to obtain registration of the file dialog is displayed automatically. Currently, the only way I can do that is to have the user to select the folder to save ahead to launch through the façade, but would like to remove this step and as soon as they clicked 'OK' on the previous dialog (file name request) have the "Save file/select the folder" dialog appear.

    Thank you

    I think you are looking for the file Express VI dialogue. Be sure to post if this isn't what you're looking for.

  • How to change the number of values in the hour that are restricted.

    Hello

    May I know how to change the number of values in the hour that are restricted.

    In fact, we have improved of obiee in obiee 11g 10g. Data base is the same for Both.In 10 g the prompt value is limited to show only 35 records per page. As we passed it shows only 35 Records in 11g also. How can I change this limit to 11g.

    Please suggest me! Its urgent!

    Thanks and greetings

    Navnitha

    Hello

    In the advance tab we have the XML of the upgraded report, copy it into a Notepad and try to find the line beginning as below

    In 10g, we have something like below, simply remove the choicesPerPage = '35' from 11 g OBIEE XML report

    Thank you

    RAM

  • Can we restrict the number of table rows to display on a page that is only 2 or 3 rows appear? How to do this?

    Mr President.

    Can we restrict the number of table rows to display on a page that is only 2 or 3 rows appear? How to do this?

    Concerning

    Tender,

    Set the RangeSize property on the table.

    See you soon

    AJ

  • Check if the user has selected box element apex before the loading of the page

    4.2.1

    THM:2

    Hello world

    I have two classic reports with different conditions but even select the columns based on a sql that uses the apex_item.checkbox2 element that allows users to select the lines and run some process. I also have a radio unit that hides and shows these two reports. However, it is possible that the user select a few lines and without doing anything click on the radio button that will present the page and all the lines that earlier he had chosen will be lost. I want that we should be able to pop an alert if there are checkboxes checked and the user tried to hit the button of the radio looks like the APEX_APPLICATION. G_F01. Count is not available at the time the page is submitted. We thought to use a pl/sql to see if APEX_APPLICATION DA. G_F01. Count > 0 then trigger an alert to confirm.

    Any ideas on how to do this?

    Thank you

    ryansun wrote:

    Hi FAC586 - basically, there are two parts of the report, were grouped products consolidated (as master) and the other report has all the products of the child. So based on the option the user selects that he sees who discovers and processes information.

    I tried to create the DA, but he does not seem to fire and I'm sure it would be because I have something wrong.

    No, in this case, there was a typing error in my JS expression above (this is what happens when there is no example in the trial against...)

    Must be:$('td[headers="COL_ALIAS"] input:checked').length > 0

    I have page submit on the evolution of radio, given that other elements of the actual application, don't do with this feature which is filled on the loading of the page.

    It does not work. If the present radio on the presentation changes group cannot be controlled by the dynamic action to confirm that it has already been committed before the confirmation message is displayed. Presentation must be made by further action of real on the DA. By the way other values is possible by using dynamic actions or region to submit elements of Page properties.

    But here it is necessary, if the user has activated all the lines, then changes the selection of the radio, it should show an alert to confirm. In addition, what happens if we have a very select in the box by a header label already. Can I use the same label to identify the COL_ALIAS?

    Do not understand the question.

    Don't know what I'm doing wrong.

    As I noted above, an important part of your problem is that you asking what amounts to a series of questions XY rather than the big picture given by presenting the necessary resources. You have been really good on the creation of examples on apex.oracle.com, but they are all fragments of the righteous, which makes things difficult when you try their synthesis in something that works as a coherent whole. Various bits and pieces that have been revealed in recent weeks, it seems like this could be treated using dynamic measurements without having to send the page until the final choice has been made.

  • I want to restrict the user manual release of the HOLD in the sales order

    Hello

    I want to restrict the user manual release of the HOLD in the sales order

    Hello

    Please use below the installation program

    1. go in responsibility: responsibility of the order management Super user.

    2. go to the Set up > order > holds > define.

    3 ask the wedge which has already been set.

    Assign at least a responsibility to a particular action as shims to apply or release, and then only hold permissions will take into account.

    4. after installation above this shim is not in the LOV when connecting other

    responsibility

    Thank you

  • Possible way is to restrict the user to the planning an application

    Hello Experts,

    I have a requirement as I want to restrict bit user related to the demand for labour in the planning depends on business unit and product.

    that is... The test user could not access of the user to the company as an employee depends on some operational units and related products. So is it possible to do outside the [Chronicle] manual process.

    Thanks in advance...

    Are you just wanting to restrict access to specific members to enter data to or it also includes being able to 'see' only the data based on some examples.  For example, in the type of financing plan, I have write access to the Dept 123 for all accounts of actual Net profit, I want they have read access to this Department?  In this case, I would make sure that specific effective accounts, that I make sure that the user/group has only read access.

    Thank you

    Mark

  • I bought the creative cloud composition and downloaded and installed on my computer. I tried to configure Adobe Acrobat 9 Standard, where he asked me my user name, organization, and serial number. They never gave me an option to add previously a U

    I bought the creative cloud composition and downloaded and installed on my computer. I tried to configure Adobe Acrobat 9 Standard, where he asked me my user name, organization, and serial number. They never gave me an option to add a user name or the organization previously, so I don't know what to put in these areas. I am also unable to find my serial number. I have received no email with a serial number in it and the list of products registered in Plans and section of my account page says "you have not saved products. Could - a member of staff if you please advise me about the installation of my product? I need the installation to download a school assignment in the next two days. Thank you in advance.

    Since this is an open forum, not Adobe support... you must contact Adobe personnel to help
    Chat/phone: Mon - Fri 05:00-19:00 (US Pacific time) <==> NOTE DAYS AND TIME
    Don't forget to stay signed with your Adobe ID before accessing the link below

    Creative cloud support (all creative cloud customer service problems)
    http://helpx.Adobe.com/x-productkb/global/service-CCM.html

Maybe you are looking for