Forum Stats

  • 3,875,109 Users
  • 2,266,806 Discussions


render af:deck child

Ofer Member Posts: 26 Red Ribbon



I have af:deck with 5 children (for this example UI components A,B,C,D,E

also i have 5 af:links , every link shows a different child accordingly when clicking it

and that using a bean. all the above works fine.

lets say I have 5 attribute bindings from the DB

(for this example we will call them A_att,B_att,C_att,D_att,E_att

on EVERY ROW that returns from the DB, those attribute returns true/ false in this way


true false false false false

true true false false false

true true true false false

true true true true false

true true true true true

my goal is to display the deck child according to the LAST true attribute that was received

on every selected row.

I tried to to this with a condition in the deck_child

#{binding.E.inputValue ne false ? 'E' :

binding.D.inputValue ne false ? 'D' :



it has two issues

  1. I have to click search twice in order for the child to be displayed, otherwise, no child is being displayed at all
  2. it stops working at all when I manually click on one of the links.

for example, if I'll click link #3 , child C will be shown,

then i do another search the displayed child will always be C despite the return attributes value. it always remains #3.

i tried to do this with a bean but didn't succedd there as well (tried to do this on the actionEvent of the search button)

can anyone please help me achieve this (if it's possible at all)

Thank you


  • Timo Hahn
    Timo Hahn Senior Principal Technical Consultant - Oracle ACE Director Member, Moderator Posts: 38,923 Red Diamond

    User, can you provide a reproducible test case, please?

    If yes, it should be built using the HR DB schema.


  • Ofer
    Ofer Member Posts: 26 Red Ribbon


    no ..but i will simplify this.. leave the DB attribute

    I have a search button that runs the following for the example


      public void search(ActionEvent actionEvent) {
        RichDeck deck = null;
        // Request
       // #{bindings.Execute_LM_requests.execute}
       ADFUtils.ExecuteOperation("MRTsummary1Iterator", "Execute_LM_requests");
       // Results
       ADFUtils.ExecuteOperation("mi_results_steps1Iterator", "Execute_MI_results"); 
      //  choose 5th deck child 
      UIComponent eventComponent = deckResultsBind;
        deck = (RichDeck) eventComponent;
        deck.setDisplayedChild("LMres"); -- this is the 5th deck child components name

    when I click search for the first time, it shows the 'LMres' child component correctly (image #1)

    but if I will choose another child (image #2) using the af:link that switches the deck's children

    and THEN I will click the search button again , no child will be displayed (image #3) it will appear as blank.

    afterward clicking the search button AGAIN will show the LMres child correctly (like in image#1)

  • dvohra21
    dvohra21 Member Posts: 14,692 Gold Crown

    Seems like after the status message in image 2, the screen needs to be refreshed somehow to display result. Click on the circular refresh button in the browser, or refresh page by some other method.

  • Ofer
    Ofer Member Posts: 26 Red Ribbon


    this should have refreshed the deck :

        deck.setDisplayedChild("LMres"); -- coosing fixed child for the example

    The idea here is that the relevant deck's child will be selected automatically (using a bean) according to data that is received from the DB.

    this should be implemented on a table row select change (SelectionEvent) .

    for example: clicking on row 1 -> can end out presenting deck's child #4

    clicking on row 2 -> and row 2 can end out showing deck's #3

    .. etc.

    all that is based on a formula inside the bean.

    in this example i choose a fixed child 'LMres' using actionEvent just to demonstrate it's not working after manually clicking a different deck's child (any other than 'LMres') before clicking on the search button.

    p.s- a similar code is being used by the <af:link> ActionEvent, which works fine -> meaning clicking manually on a link, switches the correct deck's child)

    anyone has a clue how to overcome this? is this a Bug?


  • Timo Hahn
    Timo Hahn Senior Principal Technical Consultant - Oracle ACE Director Member, Moderator Posts: 38,923 Red Diamond

    The problem I see is that we don't see what you have implemented. We have to assume that you have set up the component and code correctly. From what I see it should work. As it doesn't work, we have to assume ...

    Try to create a reproducible test case we can use to look into the problem.

    If it turns out to be a bug you need a test case anyway.