ADF Code corner 64 - select several shuttles. Help, please

Hi all.

I have exactly the same case as described in the Code corner 64.
The only difference is the name of VO and iterators.

The value of the arrived of the shuttle piece of code below:
    public Integer[] getSelectedIndxs() {
        selectedIndxs = null;
        selectedIndxList = new ArrayList<Integer>();
        
        //get all enterprise role for the current selected user role
        DCIteratorBinding aclDciter = ADFUtils.findIterator("ACLvo1Iterator");
        RowSetIterator rsi = aclDciter.getRowSetIterator();
       
        //get access to the "EnterpriseRolesVOIterator"
        DCIteratorBinding enterpriseRolesIter = ADFUtils.findIterator("EnterpriseRolesVOIterator");
        
        while(rsi.hasNext()){

            //Get the key of enterprise role of the ACL
            Row rw = rsi.next();
            Key key = new Key(new Object[] { (String)rw.getAttribute("EnterpriseRolesId") });
            
            enterpriseRolesIter.setCurrentRowWithKey(key.toStringFormat(true));

            int indx = enterpriseRolesIter.getCurrentRowIndexInRange();
            selectedIndxList.add(indx);
        }

        selectedIndxs = selectedIndxList.toArray(new Integer[selectedIndxList.size()]);
        return selectedIndxs;
    }
The value of "indx" looks good in the debugger.
I also print a list of all of the table at the end and looks very good.

The problem is that I get:
* < SimpleSelectManyRenderer > < _getSelectedItems > found no value: 12 type: java.lang.Integer among the list of the SelectItems
* < SimpleSelectManyRenderer > < _getSelectedItems > found no value: 13 type: java.lang.Integer among the list of the SelectItems
* < SimpleSelectManyRenderer > < _getSelectedItems > found no value: 10 type: java.lang.Integer among the list of the SelectItems
* < SimpleSelectManyRenderer > < _getSelectedItems > found no value: 11 type: java.lang.Integer among the list of the SelectItems
etc...

If anyone has AN idea please let me know. I'm going nuts with this...

Thank you very much! I really appreciate

Published by: apostolosk on March 15, 2012 12:06

Finally, the error was the return index. I should had returned the values - not the index.

        ArrayList selectedValues = new ArrayList();

        //get all enterprise role for the current selected user role              //DCIteratorBinding aclDciter = (DCIteratorBinding)bindings.get("ACLvo1Iterator");
        DCIteratorBinding aclDciter = ADFUtils.findIterator("ACLvo1Iterator");
        aclDciter.executeQuery();
        RowSetIterator rsi = aclDciter.getRowSetIterator();

        Row[] rw1 = rsi.getAllRowsInRange();
        for (Row rowa : rw1){
        System.out.println("display row" + rowa.getAttribute("EnterpriseRolesId"));
            selectedValues.add((String)rowa.getAttribute("EnterpriseRolesId"));
        }

        return selectedValues.toArray(new String[selectedValues.size()]);

Thank you very much.

Tags: Java

Similar Questions

  • ADF select several shuttles become read only when the value is

    Hello

    I want to ask about the select oracle ADF that many shuttle.

    Recently, I want to create a shuttle a lot with the pre value is set in the right box, select. When I try to set the value of the shuttle to select several properties. The shuttle many select transformed into an object as input like the image below text

    a.png

    but when I'm not set to select several shuttles it became normal like that

    b.png

    the method that I put in the value property is like that

    public list < BidClassification > getListBidClassificationTaken() {}

    finalClassification = new ArrayList();

    The OperationBinding class method = ADFUtil.getMethodBinding ("retrSupSupplierClassificationFindAllBySupplierId");

    method.getParamsMap () .put ("supplierId", getSelectedSupplier () .getId ());

    List < BidClassification > finalClassification = method.execute () (list < BidClassification >).

    Return finalClassification;

    }

    the method that I use to set the position data is like this

    public list < SelectItem > getListBidClassification() {}

    retval = new ArrayList();

    The OperationBinding class method = ADFUtil.getMethodBinding ("retrBidClassificationFindAll");

    listBidClassification = (list < BidClassification >) method.execute ();

    for (BidClassification bc: listBidClassification) {}

    SelectItem item = new SelectItem();

    item.setLabel (bc.getId ());

    item.setValue (bc);

    retval. Add (Item);

    }

    Return retval;

    }

    I have already replace the method equal in the BidClassification class so there will be no more no problem

    Header 1

    < af:selectManyShuttle label = 'Grading' id = 'sms1"binding =" #{backingBeanScope.backing_vendorEdit.sms1} ' "

    leadingHeader = 'Ranking Master' trailingHeader = 'Grading of provider' >

    < f: selectItems value = "#{backingBeanScope.backing_vendorEdit.listBidClassification}" id = "si1" "

    Binding="#{backingBeanScope.backing_vendorEdit.SI1}"/ >

    < / af:selectManyShuttle >

    This the jsff xml where I put the shuttle several select no defined value

    < af:selectManyShuttle label = 'Grading' id = 'sms1"binding =" #{backingBeanScope.backing_vendorEdit.sms1} ' "

    leadingHeader = 'Ranking Master' trailingHeader = 'ranking of provider.

    value = "#{backingBeanScope.backing_vendorEdit.listBidClassificationTaken}" >

    < f: selectItems value = "#{backingBeanScope.backing_vendorEdit.listBidClassification}" id = "si1" "

    Binding="#{backingBeanScope.backing_vendorEdit.SI1}"/ >

    < / af:selectManyShuttle >

    Select this the jsff xml where I put the shuttle well with the value

    someone has an idea of what's going on with this code? ___. thx a lot btw

    @

    Yeay! I already fix it!

    BTW who behave the same as me.

    You must make a note on the setter and the Get accessor of the variable list you use

    * in my case, I don't implement the setter method and the list setter method

    THX.

  • question on the example of ADF Code corner: 007-how to cancel an edit form

    Hi all
    I'm testing the example * 007.How to cancel a modification form, cancelling the changes with ADFm recording points * in the oracle ADF code corner. I downloaded * 07-application manualtaskflowsavepoints *.
    http://www.Oracle.com/technetwork/developer-tools/ADF/learnmore/index-101235.html
    everything goes well. But in my case I need the user to stay on the same page after he Cancel button clicks. then in the file config.xml adfc I changed only the case of control flow
    <control-flow-case>
     <from-outcome>return</from-outcome>
     <to-activity-id>Browse</to-activity-id>
    </control-flow-case>
    This one
         
    <control-flow-case>
     <from-outcome>return</from-outcome>
     <to-activity-id>Edit</to-activity-id>
    </control-flow-case>
    However. When I run the application and click on the edit button, I have changed a few fields on the Edit page, then press the Cancel button, nothing happen and undo changes is not performed.
    Why restorePoint does not work as it is supposed to be if we do not have navigate to another page?

    Hello

    This is because the button cancel a immediate = "true" game, which bypasses the update model phase. To see the changes, you will need to re-run the iterator of the form explicitly and then refresh it partially. You don't need to do this, when you navigate to the page of the browser, because when the page loads, the lifecycle ADF will ensure that the iterator is updated. A test, you can set immediately = 'false', in which case the redirect must display the changed data.

    Frank

  • Broken link - ADF Code corner

    Virtually all of the links on this page redirects you to the homepage of jDeveloper.

    Thank you
    Michelle

    You will notice that the content is not quite the same, but as it was on the old page. I'm still being the complete ADF Code corner documents migrated to a new format of PDF.

    ...
    >
    and

    My current plan is to make the new searchable document by time formats OQ the middle of September.

    ...>

    So I guess you'll have to wait :-(

    Timo

  • My Windows Vist shows error 8024402f update code, impossible to update windows. Help, please.

    My Windows Vist shows error 8024402f update code, impossible to update windows. Help, please.

    Hi you can try the following...

    Click on Start >
    Type in CMD > 
    Right-click on the result, and then click on run as administrator >
    Then type sfc/scannow , and then press ENTER.
    Reboot your PC and try it a few times.

    Download and install the update tool of the system for Vista (Windows Update hotfix)
    "This tool is being offered because an inconsistency was found in the maintenance shop windows which can prevent the installation of future updates and service packs software."

    Microsoft technical support suggestions:

    Configure the connection to obtain an IP address automatically

    1. Click on «Start», enter "NCPA. CPL"(without quotes) in the search bar and press"Enter. "
    2. Right-click on the network connection, and then click "Properties". If you are prompted for an administrator password or a confirmation, type the password or provide confirmation.
    3. Click Select "IP Version 6 (TCP/IPv6)" and then click "Properties".
    4. Check "obtain an IP address automatically" and "Obtain DNS server address automatically".
    5. Click on 'OK '.
    6. Click Select 'Protocol Internet Version 4 (TCP/IPv4)' and then click 'properties '.
    7. Check "obtain an IP address automatically" and "Obtain DNS server address automatically".
    8. Click on 'OK '.
    9. Restart the computer.

  • Media Player will not play new links in the toolbar in Firefox. Error code is C00D11B1. Can anyone help please?

    I downloaded a toolbar with several applications to open as videos on media player.  I have the latest plugin on firefox, but when I check my computer it says that the ffplugin.msi is missing.  Can anyone help please?

    Try this Fixit

    Solve the problems of Windows Media Player video and other media or library

    http://support.Microsoft.com/mats/windows_media_player_diagnostic

    -Or-

    Follow the instructions given in this thread on the creation of a new profile

    http://forums.mozillazine.org/viewtopic.php?f=9&p=12063593

  • ADF Code corner #50 - tree selection listener Table do not save the State of the

    Hello world

    With the help of JDev Studio Edition Version 11.1.1.3.0

    I have a table of tree using the earphone generic selection based on the excellent article by Frank Nimphius during synchronization of forms for entries of tree node edit. http://www.Oracle.com/technetwork/developer-tools/ADF/learnmore/50-synchromize-form-TreeSelection-169192.PDF

    My problem:

    My selectedNodeRowKey and selectedNodeRowIterator variables are turning to null out the listener.

    Process and code:

    I select a node. It called the selection event of onTreeSelect, which in turn saves the node key and the iterator in the same support bean backingBeanScope value.
          DCIteratorBinding _treeIteratorBinding = null;
          _treeIteratorBinding = treeBinding.getDCIteratorBinding();
    //Frank's code above ...
    
          this.selectedNodeRowKey = nodeBinding.getRowKey();
          for (Object opaqueFacesKey: treeTable.getSelectedRowKeys())
          {
            treeTable.setRowKey(opaqueFacesKey);
            this.selectedNodeRowIterator =
                ((JUCtrlHierNodeBinding) treeTable.getRowData()).getRowIterator();
          }
    
          System.out.println();
          System.out.println("Update Key: " + this.selectedNodeRowKey);
          System.out.println("Update Ite: " + this.selectedNodeRowIterator);
    
    //Frank's code resumes ...
          Row[] found =
            this.selectedNodeRowIterator.findByKey(this.selectedNodeRowKey, 1);
    Then, I click on a button that calls an actionListener in the same bean support.
      public void onButtonRemove(ActionEvent actionEvent)
      {
        System.out.println("Remove button pressed.");
    
        BindingContainer bindings = getBindings();
    
        System.out.println(this.selectedNodeRowKey);
        System.out.println(this.selectedNodeRowIterator);
    
        OperationBinding operationBinding =
          bindings.getOperationBinding("deleteChildren");
        operationBinding.execute();
        System.out.println("Remove complete");
      }
    This gives me the result
    Update Key: oracle.jbo.Key[112 ]
    Update Ite: oracle.jbo.server.ViewRowSetImpl@aa641d
    bos.model.queries.TbomView
    
    Remove button pressed.
    null
    null
    Remove complete
    What happened to my values and node iterator? I guess it has something to do with a scope or something similar to C++ through reference instead of the value. The strange thing is, the default MakeCurrent onSelection the auditor's work, but use this generic listener and values change.

    Published by: LovettWB on December 21, 2010 14:51

    Hello

    You can try setting the bean to the session scope? I guess it works, which brings me to my main point. If the managed bean is used in a stubborn workflow (which I assume you are referring to the use of fragments of page jsff), make sure that it is also defined in the workflow definition and not adfc-config. Personally, I like to feel it is best to set the bean managed in the metadata scopes, in which it is used. So could already solve the problem

    Frank

  • Cannot download an important update, error code: 80070103... ? Help please

    Windows Update told me that I had an "Important" update pending, so I tried three times to install it, but he failed each time, was error code 80070103 and download was a "significant update driver for NVIDIA GeForce 8200', my OS is Vista, could someone please inform me of what could be the problem and what can I do to activate my PC to accept this download."

    Kind regards

    Eugene

    Hello

    You get this error because Windows Update tries to install the driver that is already installed.

    Solutions:

    1 hide the update. Open Windows Update, click on the tab 'Important' right-click on the update of the selection hide update. And you will not be available to install this update.

    2 - go to start > Control Panel > program and features > uninstall the driver NVIDIA GeForce 8200, and then run Windows update.

    Hope this helps,

  • I had trouble with my desktop application. There is a new version 2.0.0.74 availible and it only downloadfs to 5% and I get an error code: 42. I need your help please

    I have experienced difficulty to install an updated version 2.0.0.74 on my desktop creative cloud app when saying install now it downloads to only 5 percent, and then it gives me an error code: 42. I did the part of redemption code and all my software expired. I use Windows desktop. I contacted directly at your offices and talked to the sales representatives, and they do not know how to help.

    Hello

    Please delete your temporary folder and delete the files. After that download the app office creative cloud from the link below:

    Using creative cloud | Creative cloud to desktop

    Kind regards

    Sheena

  • I think I bought the software, but I have not received the code to install the software. Help, please!

    How can I get the code to download the software?

    If you have purchased a subscription to the cc, download cc desktop app, https://creative.adobe.com/products/creative-cloud

    and use the application to install your programs.

    otherwise:

    Available downloadable Setup files:

    Download and installation help links Adobe

    Help download and installation to Prodesigntools links can be found on the most linked pages.  They are essential; especially steps 1, 2 and 3.  If you click on a link that does not have these listed steps, open a second window by using the link to Lightroom 3 to see these "important Instructions".

    window using the Lightroom 3 link to see these "important Instructions".

  • Cannot change the value in the report url column in the select statement. Help, please

    Hi all
    I'm moving the value of the column of the report as follows:
    select key, num,
    case when Attachmentcnt(KEY) != 0 then
    'f?p=&APP_ID.:91:&SESSION.:'' '':NO::P91_KEY,P91NUM,P91_PREVPG:'
    And I'm passing the values as follows:

    {noformat}
    "#KEY #, ' NUM # #', 9' ELSE null.
    Fixing of END
    from tableA
    {noformat}

    But I'm not able to understand correct syntax for these column values. Can someone give me help. I appreciate it.
    Rgds,
    Suma.

    Published by: sumak on June 23, 2009 12:11

    Published by: sumak on June 23, 2009 12:22

    Suma,

    If you try to generate a column with a URL, try something like the following:

    Select the key, num,
    -case when Attachmentcnt (KEY). = 0 then
    ' f ? p = & APP_ID.: 91: & SESSION. : "": NO::P91_KEY, P91NUM, P91_PREVPG:'
    || tableA.key | ',' || tableA.num | ',' || : P91_PREVPG
    Another null
    end
    FROM tableA;

    But the best way to spend these would include values of checksum against the values of your parameters (to ensure that a user is not hack them). You will need to check the manual of the Apex for more details - see "Understanding Session State Protection".

    Good luck

    Stew

  • How can we use select ADF component user interface of many shuttles in applications of OIM 11 g R2 PS2

    Hi Experts,

    How can we add an ADF also select several shuttles on the Instance of the Application form, if asked how we can add values for search through managed bean. I have seen a few examples to select several shuttle for ADF controller projects but the component on .jspx in IOM we have .jsff. I also tried with these example through backing bean, but not able to get the values for the ADF to select several shuttles component on the user interface. Please answer if someone has worked on this requirement, which would be a great help.

    Kind regards

    Shantanu

    Hello

    I'm able to reach the scenerio above using the Web ADF SelectManyShuttle and stores the value on the field of application of text entry form. If the closure of this post.

    Kind regards

    Shantanu Pradhan

  • ADF Code Corder 42: by using a &lt; af:poll &gt; with an Application Module

    Hi all

    With the help of JDev 11.1.2.3.0.

    I worked to solve this puzzle for a while.  I'm trying to implement a simplified version of the ADF Code corner #42 (http://www.oracle.com/technetwork/developer-tools/adf/learnmore/42-progressbarcolor-169184.pdf)

    The thing is that my 'business ' service is running in my module of the application.  In short, I take 10,000 rows to view object and run through a few different algorithms.  It would be nice to give a report during this operation.  However, as soon as I start my method of request module, my component < af:poll > end, refusing to update the current page.

    I watched a lot of sites tutorials to try to solve this problem.  I try to stay within the limits of the ADF Essentials which means no ADVERTISING, only of the poll.  Here are some of the best references:

    GEBS | Oracle Fusion Middleware 11g ADF progress indicator

    Refresh the page periodically by using survey components |

    Their service 'business' in the managed bean and the other simply re - runs a page runs a view object.  I can't find a site that will their own business service and surveys it.  Here's what I have:

    Application module

        private long uploadStatus;
    
    
        public void doUpload() {
            long max = this.getMaximum();
            for(this.uploadStatus = 0; this.uploadStatus <= max ; this.uploadStatus += 500){
                System.out.println("@ " + this.uploadStatus);
                try {
                    TimeUnit.SECONDS.sleep(1);
                } catch (InterruptedException e) {
                    e.printStackTrace();
                }
            }
            System.out.println("Upload Complete");
        }
    
        public long getStatus(){
            return this.uploadStatus;
        }
    
        public long getMaximum(){
            return 10000;
        }
    

    Backing Bean

    public class ProgressBarModel extends BoundedRangeModel {
    
        private long max;
        private long status;
    
        Thread newProgress = null;
    
        public ProgressBarModel() {
            this.getMaximum();
            this.getValue();
        }
    
        @Override
        public long getMaximum() {
            // Not best practice. Should get through page def method operation
            AppModuleImpl am = (AppModuleImpl)ADFUtils.getApplicationModule("AppModuleDataControl");
            this.max = am.getMaximum();
            return this.max;
        }
    
        @Override
        public long getValue() {
            System.out.println("polling ...");
            AppModuleImpl am = (AppModuleImpl)ADFUtils.getApplicationModule("AppModuleDataControl");
            this.status = am.getStatus();
            return this.status;
        }
    
        public void doUpload(ActionEvent actionEvent) {
            if (newProgress != null) {
                newProgress.interrupt();
            }
    
            ProgressUpdater progressSimulator = new ProgressUpdater();
            newProgress = new Thread(progressSimulator);
            newProgress.run();
    
        }
    
        public void stopUpload() {
            newProgress.interrupt();
            newProgress = null;
        }
    
        class ProgressUpdater implements Runnable {
            public void run() {
                AppModuleImpl am = (AppModuleImpl)ADFUtils.getApplicationModule("AppModuleDataControl");
                am.doUpload();
            }
        }
    
        public long getPercentageUploaded() {
            long state = this.status * 10 / 10000;
            if(state >= 100){
                this.stopUpload();
            }
            return this.status * 100 / 10000;
        }
    }
    

    JSPX

    <af:panelFormLayout id="pfl1">
                                    <af:poll id="pollid" interval="1000"/>
                                    <af:outputFormatted value="#{MyProgressRangeModel.percentageUploaded}% completed"
                                                        id="of1" partialTriggers="pollid"/>
                                    <af:commandToolbarButton actionListener="#{MyProgressRangeModel.doUpload}" text="Run"
                                                            id="ctb1"/>
    </af:panelFormLayout>
    

    Give me the result

    polling ...
    polling ...
    polling ...
    @ 0
    @ 500
    @ 1000
    @ 1500
    @ 2000
    @ 2500
    @ 3000
    .... // up to 10000
    Upload Complete
    polling ...
    polling ...
    

    How can I get the survey allows you to control when the method of the module of an application is running?  Use more than one module app, for inclusion in the database and the other for monitoring?

    Thank you

    Will be

    I went with that instead

    How I finally reached updates to asynchronous UI with WebSockets and JMS

  • Made a shuttle elimate select several duplicates - JDev 11 1.2

    Hello:

    A multi-Select shuttle component automatically eliminates duplicate values on the available (based on the primary key) to select (left side) and the side selected (right)? In other words, the component selection multiple shuttle should prevent the same record on the right and left sides. Is this correct?

    Thanks for the help.

    It eliminates automatically, but you have to store these values and fill again later...

    AF:selectManyShuttle component requires start and end as java.util.List values, you can create a list of your iterator or static values.

    Watch this video and download sample code http://baigsorcl.blogspot.com/2010/10/creating-shuttle-component-in-oracle.html

    Zitouni

  • I've just upgraded to PSE 12 and first E 12 and tried to installed several times.  Pop up says "Configuration Error"; contact Adobe Tech Support (?); and "mention the error code 1"!  Help please!

    I've just upgraded to PSE 12 and first E 12 and tried to installed several times.  Pop up says "Configuration Error"; contact Adobe Tech Support (?); and "mention the error code 1"!  Help please!

    Installation seems to work fine until, and including 'Technologies share '...

    I have cleaned all the disk *.tmp files, deleted all the shortcuts and various Adobe programs and he then successfully installed.

    Now, if I can get the updates to work.  There is always a challenge with the Adobe software.

Maybe you are looking for