Is it possible to change LOV definition using dynamic action?

Hi,
I have a multi-select LOV page item, P27_MULTI_CLASS_CODE, defined as below.  On page load, this list only contains values based on what has been passed to P27_OLO_CODE or P27_OLO_CODE_SW.
SELECT DISTINCT c.class_code d, c.class_code r
  FROM ORGANIZATION o,
       POSITION p,
       CLASS c
WHERE o.org_wk = p.org_wk
   AND p.class_wk = c.class_wk
   AND o.org_active_flag = 'Y'
   AND p.pos_active_flag = 'Y'
   AND c.class_active_flag = 'Y'
   AND (o.olo_code = :P27_OLO_CODE
        OR o.olo_code = :P27_OLO_CODE_SW)
ORDER BY c.class_code ASC
Before submitting the page, I would like the LOV definition of P27_MULTI_CLASS_CODE to change to the following (similar query without reference to P27_OLO_CODE or P27_OLO_CODE_SW) based on whether the user selects checkbox item, P27_ALLOW_SW.   By doing this, P27_MULTI_CLASS_CODE would contain a full range of values rather than limited values.
SELECT DISTINCT c.class_code d, c.class_code r
  FROM ORGANIZATION o,
       POSITION p,
       CLASS c
WHERE o.org_wk = p.org_wk
   AND p.class_wk = c.class_wk
   AND o.org_active_flag = 'Y'
   AND p.pos_active_flag = 'Y'
   AND c.class_active_flag = 'Y'
ORDER BY c.class_code ASC
I wanted to avoid writing Javascript.  Is this possible using dynamic actions...or at least somehow refresh P27_MULTI_CLASS_CODE so that it ignores P27_OLO_CODE and P27_OLO_CODE_SW?
I've tried creating a dynamic action to clear the value of  P27_OLO_CODE or P27_OLO_CODE_SW, in hope it would trigger P27_MULTI_CLASS_CODE to display all values, but it has not been successful.  Any ideas?
APEX 4.2

I was able to resolve by changing the SQL statement to P27_MULTI_CLASS_CODE.  Note:  I also included an additional condition.
SELECT DISTINCT c.class_code d, c.class_code r
  FROM ORGANIZATION o,
       POSITION p,
       CLASS c
WHERE o.org_wk = p.org_wk
   AND p.class_wk = c.class_wk
   AND o.org_active_flag = 'Y'
   AND p.pos_active_flag = 'Y'
   AND c.class_active_flag = 'Y'
   AND (:P27_ALLOW_SW = 'Y'
        OR (o.olo_code =  :P27_OLO_CODE
            OR o.olo_code = :P27_OLO_CODE_SW)
   AND (:P27_PAY_PLAN IS NULL
         OR p.pay_plan = :P27_PAY_PLAN)
ORDER BY c.class_code ASC
I also changed the Cascading LOV Parent Item(s) value to:  P27_OLO_CODE,P27_OLO_CODE_SW,P27_PAY_PLAN,P27_ALLOW_SW.  Optimize Refresh = No, since a change in any one of these values should trigger refresh of LOV.
The Dynamic Action was also modified to NULL out P27_OLO_CODE,P27_OLO_CODE_SW when P27_ALLOW_SW was enabled.
So far, so good!  Thanks for your suggestions Tom and Howard!

Similar Messages

  • Set Cascading LOV Item using Dynamic Action

    Hi all,
    I have the following page item:
    P1_USERNAME
    P1_COMPANY  (LOV)
    P1_DIVISION (LOV)
    P1_DEPT (LOV)
    Item P1_COMPANY, P1_DIVISION, and P1_DEPT are cascading LOV on my page.
    I also have a table that contains the user and his/her company, division, and department.
    So I have a dynamic action that when P1_USERNAME is entered. The dynamic action will pull the COMPANY, DIVISION, and DEPT information from the table and populate the page item accordingly.
    I got the dynamic action working, I can confirm this by checking the Session State of the items.
    BUT I cannot get the LOVs to display the selected value from the session state. They always reset back to "- Please Select -", which is my display value when NULL.
    For example:
    I have a record like in the table:
    Username :alex
    Company : Finance Inc.
    Division : Admin
    Dept : HR
    When I entered the username into P1_USERNAME, this is what I see in the screen.
    Username :alex
    Company : - Please Select -
    Division : - Please Select -
    Dept : - Please Select -
    While the session states of the items have been set correctly as per the record in the database.
    Has anyone experienced this before?
    I think it's because the parent LOV (company), reset the child LOVs (division and dept), when the dynamic action kicks in.
    Thanks.

    I've just taken a look at your sample page and don't think this issue is actually too complicated to solve. (Actually, it was I who was mucking around in page 1, sorry for that. I was looking at it and then had to go. Picked it up again later on and just made a copy this time)
    You change the employee. The dynamic action fires, executes plsql and sets the values in the company2/division2/dept2 fields
    Company 1 is a cascading lov. Empo has changed? Company refreshes. Cascading for division and dept as well.
    You can see this happening in sequence as well when looking at the page. Select emp, it'll hang for a second. You then get the select list refresh icons.
    The sequence in which this happens is of course a bit wrong. You set the values for the items on the client side first, but then their refresh is kicked in, and so the value setting is simply lost again.
    What makes this annoying is how P1_EMPNO is a cascading lov parent of P1_COMPANY. Changing P1_EMPNO will refresh the lovs beneath it. However, you can't simply set their values after you've retrieved the user's company/division/dept, because each lov is dependent on the one above it. Eg you change the employee. The company lov is refreshed. Because the it is refreshed, the division lov will refresh. Now you can set the value of the company lov, but not that of the division one. Why is this? The lov for division requires the value of company in the session state. If you'd set the value for company after it has finished refreshing, it will already be too late for division to pick up the value set. .
    I made a copy of your page to page 5, “tom”.
    The first I did was removing the cascade from the company lov. You don’t need this. There are simply no parent lovs for this lov, as is evident from the sql for it. The companies always remain the same companies even when you select another person; it is not dependent on another item for its values.
    Then the timing issues come in play, and with them there is also the issue of the session state.
    So now companies always show. You pick a user, it runs the PLSQL block and put values in the P5_xxx2 items. P5_COMPANY can be set now, and this is in the set value of the dynamic action. By not suppressing the change event, a refresh will be triggered on its cascading lov, P5_DIVISION.
    Refreshing P5_DIVISION will only get the new lov values (constrained within the chosen company) for this item though, and not set the value. We already have the values in P5_DIVISION2 however, and thus can use the “After Refresh” dynamic action on P5_DIVISION to do this. In short: company gets set, divisions refresh to show the correct divisions, and then the selected value is set. Again, by not suppressing the change event on this item the depending lov on DEPT will be refreshed.
    Then by using another “After Refresh” dynamic action on P5_DEPT we can set the selected value once more.
    Also important is that I changed P5_DIVISION to submit P5_COMPANY when it is refreshed, and P5_DIVISION when P5_DEPT is refreshed. This makes sure that the correct set of values is retrieved and probably why you were struggling aswell. After company has changed and division has refreshed, the value on division is set. But the correct divisions are shown only because the chosen company has been set in the session state.
    The same for division - dept. After the refresh of division, the chosen value for division is set. This change will trigger the refresh on dept, and because dept has the division in its page items to submit list, the correct values will be retrieved.
    Take note that the “debug items” are required in this solution though. Just set them as hidden and unprotect their value. Your goal should be to reduce the amount of roundtrips to the server. Why do a plsql (ajax) call just to retrieve a session state, when the value is already on the page and all in one action? Three hidden items is just so much easier than 3 extra ajax calls, the tradeoff is plenty.
    There is one more noteworthy point, and that is the fact that dept is being retrieved twice. That makes sense because of the cascading lovs. Initially company is changed, and this will refresh division and this in turn will trigger a refresh on dept. At this point the lov for dept will be empty, because division will be empty. Because we set the value of division again after it has refreshed, this will trigger a second refresh on dept, though now the correct list of values is retrieved because division has a value set. Not that big an issue, but good to point out. If you’d have another cascading lov beneath dept, it would refresh three times.

  • Is it possible to change instance and use OEM ?

    We have 4 single DB instance in same oracle 11gr2 server on win2008R2.
    We will not use grid control because of lack of time, knowledge and customer approval.
    Is it possible to change instance and use OEM by changing ORACLE_UNQNAME variable or in any way ?

    840105 wrote:
    IF what EdStevens said is true,
    WHat environmental variable ,or othe settings shoud I set to start 4 different dbconsole and access those OEM in same server ?
    "IF" what I said is true???
    The same environment variables you set to start the database itself .....
    Here's the environment with no oracle-specific settings:
    oracle:$ env | grep ORA | sort
    PS1=\n\u:$ORACLE_SID$
    Now we set the environment for database 'orcl'
    oracle:$ . oraenv
    ORACLE_SID = [oracle] ? orcl
    The Oracle base for ORACLE_HOME=/u01/app/oracle/product/11.2.0/db_1 is /u01/app/oracle
    Now the environment looks like this:
    oracle:orcl$ env | grep ORA | sort
    ORACLE_BASE=/u01/app/oracle
    ORACLE_HOME=/u01/app/oracle/product/11.2.0/db_1
    ORACLE_SID=orcl
    PS1=\n\u:$ORACLE_SID$
    Start the dbcontrol
    oracle:orcl$ emctl start dbconsole
    Oracle Enterprise Manager 11g Database Control Release 11.2.0.1.0
    Copyright (c) 1996, 2009 Oracle Corporation.  All rights reserved.
    https://vblnxsrv01.vbdomain:1158/em/console/aboutApplication
    Starting Oracle Enterprise Manager 11g Database Control ........................... started.
    If Oracle would only provide documentation ... oh, wait!
    Getting Started with Database Administration
    Managing Oracle Enterprise Manager Database Control

  • Is it possible to change nunmber of columns dynamically in table control

    Is it possible to change number of columns dynamically in table control? if so how it could be done?
    Thnaks in advance.
    Sounder

    You can update the table control in your program, the table control is a structure of the type CXTAB_CONTROL of TYPE-POOLS cxtab.
    There you can hide or display column the same way you do for fields in LOOP AT SCREEN. there you will ahve to LOOP AT <control>-COLS.
    TYPE-POOL CXTAB .                                                                               
    TYPES:                                                                               
    BEGIN OF CXTAB_COLUMN,                                                          
             SCREEN      LIKE SCREEN,     "Attributes struktur SCREEN                      
             INDEX       TYPE I,         "Position of a column on the screen               
             SELECTED(1) TYPE C,          "Indicator 'column selected'                     
             VISLENGTH   LIKE ICON-OLENG, "Visualised length of a column                   
             INVISIBLE(1) TYPE C,         "Indicator 'column invisible'                    
           END   OF CXTAB_COLUMN,                                                                               
    BEGIN OF CXTAB_CONTROL,                                                         
             FIXED_COLS    TYPE I, "Number of fixed columns                                
             LINES         TYPE I, "Number of lines to display                             
             TOP_LINE      TYPE I, "Top line during next PBO                               
             CURRENT_LINE  TYPE I, "Current line during LOOP/ENDLOOP                       
             LEFT_COL       TYPE I, "Fist scrollable column after fixed area               
             LINE_SEL_MODE    TYPE I, "Line-selection  : none(0), single(1),               
             COL_SEL_MODE     TYPE I, "Column-selection:        multiple(2)                
             LINE_SELECTOR(1) TYPE C, "Indicator: 'With line-selection col'                
             V_SCROLL(1) TYPE C,            "not used                                      
             H_GRID(1) TYPE C,        "Indicator: 'Horizontal  grid-lines'                 
             V_GRID(1) TYPE C,     "Indicator: 'Vertikal    grid-lines'                    
             COLS      TYPE STANDARD TABLE OF CXTAB_COLUMN                                 
                            WITH NON-UNIQUE DEFAULT KEY,                                   
             INVISIBLE(1) TYPE C,                                                          
           END   OF CXTAB_CONTROL,                                                         
    Regards

  • How to make a default value by using dynamic actions

    Hi,
           I want to default a field nationality in infotype 0002 as a great britan, using dynamic actions but unable to go ahead. Any help regarding this really appreciate.
    Regards
    Niranjan

    Hi,
    I need some guidance around creating dynamic action with default value, Please guide me through.
    I am aware I can set default values for new infotype, but I need to set default value for same infotype, let me explain the scenario.
    Currently employee is on one pension scheme which is called NE1 and now we are moving this employee to CRESP Pension Scheme.
    When employee is in NE1, his IT0071 has got a opt in field with a flag on, when the same employee is moved from NE1 pension scheme to CRESP Pension scheme, his new IT0071 record should have the same opt in field with a flag on, I want it to set this flag automatically using dynamic action. I dont want to update this field manually, while moving from NE1 to CRESP.
    Currently the below dynamic  action is coded when employees are being moved form NE1 to CRESP, but now they will have a opt in flag which should appear automatically, What needs to be done to make this happen?
    Please let me know if I set default value for the Opt in field for the same infotype.
    . When employees are being moved from NE1 to CRESP pension scheme we currently use a dynamic action as show below:
    0071                      04      10      I        INS,0069
    0071                      04      20      W       P0069-BEGDA=P0071-BEGDA
    0071                      04      30      W       P0069-ENDDA=P0071-ENDDA
    0071                      06      1        F        DYNACT_PAE031(ZHRPROG016)
    Also if it is not possible via dynamic action could you please explain how to create it using user exit, I am not an ABAPer.
    Your help is very much appreciated.
    Kind Regards,
    SK

  • About creating an AJAX page with DML procedures  using dynamic actions

    About creating an AJAX page with DML procedures in APEX using dynamic actions. Help with limitations.
    I want to share my experience, creating AJAX procedures in APEX 4.0.
    LIMITATIONS
    •     How Can I Hide UPDATE button while I press NEW button. ??
    •     How Can I Hide CREATE button while I’m UPDATING A RECORD. ??
    •     How can I avoid multiple Inserts or Updates. ??
    Here are the steps to create an AJAX Updatable Form using the sample table DEPTS. You can see the demo here: [http://apex.oracle.com/pls/apex/f?p=15488:1]
    1)     Create a blank page
    2)     Add a Report Region for departments (It shows the columns deptno, dname and loc).
    3)     Add an HTML Region and create the elements to edit a Department.
    a.     P1_DEPTNO (Hidden to store PK)
    b.     P1_DNAME (Text Field)
    c.     P1_LOC (Text Field)
    4)     You also have to create a hidden element called P1_ACTION. This will help to trigger dynamic actions to perform DMLs.
    5)     Open Page Attributes and in the HTML Header Section include the following code.
    <script>
         function doSelect(pId){
              $x_Value(‘P1_DEPTNO’,pId);
              $x_Value(‘P1_ACTION’,’SELECT’);
    </script>
    6)     Modify the column DEPTNO in the report, to add column link. In the link text you can use #DEPTNO# , in target you must select ‘URL ‘ and in the URL field write javascript:doSelect(#DEPTNO#);
    7)     Create the following Buttons in the Form Region.
    CANCEL     Redirects to URL: javascript:$x_Value(‘P150_ACTION’,’CANCEL’);
    NEW          Redirects to URL: javascript:$x_Value(‘P150_ACTION’,’NEW’);
    SAVE          Redirects to URL: javascript:$x_Value(‘P150_ACTION’,’UPDATE’);
    CREATE          Redirects to URL: javascript:$x_Value(‘P150_ACTION’,’CREATE’);
    8)     Create the following Dynamic Action to Select a Department
    Name:     Select Dept
    Event:     Change
    Selection Type:     Item(s)
    Item(s):     P1_ACTION
    Condition:     equal to
    Value:     SELECT
    Action:     Execute PL/SQL Code
    PL/SQL Code:     
    SELECT dname, loc
    INTO :P1_DNAME, :P1_LOC
    FROM dept
    WHERE deptno = :P1_DEPTNO;
    Page Items to Submit:     P1_DEPTNO, P1_DNAME, P1_LOC     
    Don’t include any false action and create the Dynamic Action.
    The first limitation, the value of page elements don’t do refresh so I added the following true actions to the dynamic action AFTER Execute PL/SQL Code.
    Action:     Set Value
    Unmark *‘Fire on page load’* and *‘Stop execution on error’*
    Set Type:     PL/SQL Expression
    PL/SQL Expression:     :P1_DNAME
    Page Items to submit:     (none) (leave it blank)
    Affected Elements: Item P1_DNAME
    Action:     Set Value
    Unmark *‘Fire on page load’* and *‘Stop execution on error’*
    Set Type:     PL/SQL Expression
    PL/SQL Expression:     :P1_LOC
    Page Items to submit:     (none) (leave it blank)
    Affected Elements: Item P1_LOC
    These actions allow refresh the items display value.
    9)     Create the following Dynamic Action to Update a Department
    Name:     Update Dept
    Event:     Change
    Selection Type:     Item(s)
    Item(s):     P1_ACTION
    Condition:     equal to
    Value:     CREATE
    Action:     Execute PL/SQL Code
    PL/SQL Code:     
    UPDATE dept SET
    dname = :P1_DNAME,
    loc = :P1_LOC
    WHERE deptno = :P1_DEPTNO;
    Page Items to Submit:     P1_DEPTNO, P1_DNAME, P1_LOC     
    Don’t include any false action and create the Dynamic Action.
    Include the following True Actions BEFORE the Execute PL/SQL Code true Action.
    Action:     Set Value
    Unmark ‘Fire on page load’ and ‘Stop execution on error’
    Set Type:     PL/SQL Expression
    PL/SQL Expression:     :P1_DNAME
    Page Items to submit:     P1_DNAME
    Affected Elements: Item P1_DNAME
    Action:     Set Value
    Unmark *‘Fire on page load’* and *‘Stop execution on error’*
    Set Type:     PL/SQL Expression
    PL/SQL Expression:     :P1_LOC
    Page Items to submit:     P1_LOC
    Affected Elements: Item P1_LOC
    These actions allow refresh the items display value.
    Finally to refresh the Departments report, add the following true action at the end
    Action:     Refresh
    Affected Elements: Region Departments
    10)     Create the following Dynamic Action to Create a Department
    Name:     Create Dept
    Event:     Change
    Selection Type:     Item(s)
    Item(s):     P1_ACTION
    Condition:     equal to
    Value:     CREATE
    Action:     Execute PL/SQL Code
    PL/SQL Code:     
    INSERT INTO dept(deptno,dname,loc)
    VALUES (:P1_DEPTNO,:P1_DNAME,:P1_LOC);
    Page Items to Submit:     P1_DEPTNO, P1_DNAME, P1_LOC     
    Don’t include any false action and create the Dynamic Action.
    Include the following True Actions BEFORE the Execute PL/SQL Code true Action.
    Action:     Set Value
    Unmark *‘Fire on page load’* and *‘Stop execution on error’*
    Set Type:     PL/SQL Function Body
    PL/SQL Function Body:     
    DECLARE
    v_pk NUMBER;
    BEGIN
    SELECT DEPT_SEQ.nextval INTO v_pk FROM DUAL;; -- or any other existing sequence
    RETURN v_pk;
    END;
    Page Items to submit:     P1_DEPTNO
    Affected Elements: Item P1_DEPTNO
    Action:     Set Value
    Unmark *‘Fire on page load’* and *‘Stop execution on error’*
    Set Type:     PL/SQL Expression
    PL/SQL Expression:     :P1_DNAME
    Page Items to submit:     P1_DNAME
    Affected Elements: Item P1_DNAME
    Action:     Set Value
    Unmark ‘Fire on page load’ and ‘Stop execution on error’
    Set Type:     PL/SQL Expression
    PL/SQL Expression:     :P1_LOC
    Page Items to submit:     P1_LOC
    Affected Elements: Item P1_LOC
    These actions allow refresh the items display value.
    Finally to refresh the Departments report, add the following true action at the end
    Action:     Refresh
    Affected Elements: Region Departments
    11)     Create the following Dynamic Action to delete a department
    Name:     Delete Dept
    Event:     Change
    Selection Type:     Item(s)
    Item(s):     P1_ACTION
    Condition:     equal to
    Value:     DELETE
    Action:     Execute PL/SQL Code
    PL/SQL Code:     
    DELETE dept
    WHERE deptno = :P1_DEPTNO;
    Page Items to Submit:     P1_DEPTNO
    Don’t include any false action and create the Dynamic Action.
    Include the following True Actions AFTER the Execute PL/SQL Code true Action.
    Action:     Refresh
    Affected Elements: Region Departments
    Action:     Clear
    Unmark ‘Fire on page load’
    Affected Elements: Items P1_DEPTNO, P1_DNAME, P1_LOC
    12)     Finally Create the following Dynamic Action for the NEW event
    Name:     New Dept
    Event:     Change
    Selection Type:     Item(s)
    Item(s):     P1_ACTION
    Condition:     equal to
    Value:     NEW
    Action:     Clear
    Unmark *‘Fire on page load’*
    Affected Elements: Items P1_DEPTNO, P1_DNAME, P1_LOC

    I need some help to solve this issues
    •     How Can I Hide UPDATE button while I press NEW button. ??
    •     How Can I Hide CREATE button while I’m UPDATING A RECORD. ??
    •     How can I avoid multiple Inserts or Updates. ??

  • Sending mail of infotype record using dynamic actions

    Hi
    How can we send mail of info type record using dynamic actions if possible give me one example
    Mail to me: [email protected]
    Thanks & Regards
    santhosh reddy

    Hi..
    Already Standard Entries exists for the same.. pls check T588Z

  • Sending mails using dynamic actions

    Hi
    How we can send mails using dynamic actions.
    Regards
    Santhosh

    Hi,
    Sending mails is possible by using the feature M0001. This is to be coded in the dynamic action depending on the requirement with function code "M".
    Hope this would help you to explore further. Incase of any specific query you can post back.
    Regards
    Tharak

  • How to use dynamic action to fill multi item on a page ?

    Hi..
    I want to fill multi items on a page so I build a dynamic action ( Execute PL/SQL Code ) to do it .The problem is that when the page loads I can't see any data and I tried to see the session values using debug and I found data. Moreover when I save the row I got these data saved.
    So what is the magic there?
    Thanks

    Firstly, to get the multi-select populated with "pre-selected" values the easiest approach is to use Computation or Process at a process point On Load Before Header or After Header or Before Regions.
    All you need to do is populate your "Select List " page Item with : (colon) separated list of selected values. E.g is you want A,B and C out of A,B,C,D,E selected then get A:B:C into the Page Item.
    If you have used Dynamic Actions, what is your event on which the action fires? For Dynamic-Actions the page (HTML DOM) needs to be existing , so it must fire after the page has loaded.
    Regards,

  • Why we are using dynamic actions in HR

    why we are using dynamic actions in HR?? main purpose of it>>

    Check the link -
    Re: Dynamic Actions
    Re: dynamic actions
    Re: Dynamic Actions
    www.hrexpertonline.com/downloads/Rehan%20Zaidi%20Online%20Portion.doc
    Regards,
    Amit
    Reward all helpful replies.

  • Send mail using Dynamic actions

    Hello experts,
    How to send  a mail using Dynamic Actions??
    Requirement : Lets say one employee is hired on 26th Aug, so after 10 days he will be confirmed. so on 8th day need to send a mail to concerned person reminding the confirmation date.
    so how do i do that using dynamic actions??
    Thanks in advance.
    Saurabh

    Hi,
    In dynamic actions there is an option for calling sub-routine from any program or subroutine pool. So u can make subroutine for sending mail according to ur requirement. An call on th same from dynamic actions.
    if u want sample code for this, pls let me know.
    <removed_by_moderator>
    Regards,
    Ranjith
    Edited by: Julius Bussche on Aug 26, 2008 3:25 PM

  • Change Directory Path using Dynamic Configuration

    Hi,
    We have a requirement where the directory path for placing the files is different across our different environments. Ex: Development Environment has a different path than the Quality Enviornmnet. Also the full path is depending on fileds within the message.
    I want to use Dynamic Configuration to create the Directory path. But in order to capture the full requirement I need to know wheich environment I am within the User Defined Function.
    Can someone provide me the java class and function that I can use in my UDF to read the environment I am in.
    ( Essentially I want to read Sy-SYSID in ABAP...using Java. )
    Regards,
    Arunava

    Hi Arunva,
    >>Essentially I want to read Sy-SYSID in ABAP...using Java.
    It might not be possible to read system id in java, but you can read the sender or receiver service(SENDER_SERVICE or RECEIVER_SERVICE) and based on it can decide the diretory in DynamicConfiguration.
    If you have a sender or receiver SAP sysem then better to read its name because this business systm ill haeunique name aross different environment. Check this thread too
    User-defined function: RFC call
    Regards
    Suraj

  • Is it possible to create an array using Advaced Actions?

    I need to create an interaction where the user can make selections from a long list of items on multiple slides. I want to store these 'customized selections' in a an array so that at the end of the course, I can display specific feedback that relates to the selections the user made throughout the course. Is it possible to do so using Advanced Actions? Can anyone point me to a resource that describes how I might accomplish this functionality?
    Thanks!

    It depends how you create the 'selections', how many items can be selected (all of them?) and how you'll create the feedback based on those selections. There are plenty of use cases with advanced actions on my blog.
    Another approach would be to use JavaScript of course.
    Lilybiri

  • How to Use Dynamic Action ?

    Dear All,
    i am using Apex 4.1 Ver.
    i need return value in text Area Item when i select any Value in Select List.
    i have One select List Item :p1_template_id and one text Area Item P1_template_description .
    Select List Code
    SELECT TEMPLATE_NAME D, TEMPLATE_ID R FROM TEMPLATE_MAS  ORDER BY TEMPLATE_NAME
    Table Name
    CREATE TABLE  "CRM_CAM_TEMPLATE_MAS"
       (     "TEMPLATE_ID" VARCHAR2(50) NOT NULL ENABLE,
         "TEMPLATE_NAME" VARCHAR2(500) NOT NULL ENABLE,
         "DESCRIPTION" CLOB
          CONSTRAINT "CRM_CAM_TEMPLATE_MAS_PK" PRIMARY KEY ("TEMPLATE_ID") ENABLE
    /i want to Value of DESCRIPTION Column in to Text Area Item when i select Template ID from Select List .
    How can i do this with Dynamic Action or any other Way ?
    How can i do this ?
    Thanks
    Vedant

    Hi Kiran,
    i have done it with Text Area but when i change text Area with Rich Text Editor then it's not Working.
    How can i do this with Rich Text Editor.
    My Code
    Application Process
    DECLARE
       v_mgr  VARCHAR2(4000);
       CURSOR cur_c
       IS
    SELECT DESCRIPTION FROM TEMPLATE_MAS WHERE TEMPLATE_ID =:TEMPLATE_ITEM ;
    BEGIN
       FOR c IN cur_c
       LOOP
          v_mgr := c.DESCRIPTION;
       END LOOP;
       OWA_UTIL.mime_header ('text/xml', FALSE);
       HTP.p ('Cache-Control: no-cache');
       HTP.p ('Pragma: no-cache');
       OWA_UTIL.http_header_close;
       HTP.prn ('<body>');
       HTP.prn ('<desc>this xml genericly sets multiple items</desc>');
       HTP.prn ('<item id="P1_SUMMARY">'||v_mgr|| '</item>');
       HTP.prn ('</body>');
    EXCEPTION
       WHEN OTHERS
       THEN
          OWA_UTIL.mime_header ('text/xml', FALSE);
          HTP.p ('Cache-Control: no-cache');
          HTP.p ('Pragma: no-cache');
          OWA_UTIL.http_header_close;
          HTP.prn ('<body>');
          HTP.prn ('<desc>this xml genericly sets multiple items</desc>');
          HTP.prn ('<item id="P1_SUMMARY">'||SQLERRM||'</item>');
          HTP.prn ('</body>');
    END;
    Java Script
    <script language="JavaScript" type="text/javascript">
    <!--
    function pull_multi_value(pValue){
        var get = new htmldb_Get(null,html_GetElement('pFlowId').value,
        'APPLICATION_PROCESS=TEMPLATE_ITEM1',0);
    if(pValue){
    get.add('TEMPLATE_ITEM',pValue)
    }else{
    get.add('TEMPLATE_ITEM','null')
        gReturn = get.get('XML');
        if(gReturn){
            var l_Count = gReturn.getElementsByTagName("item").length;
            for(var i = 0;i<l_Count;i++){
                var l_Opt_Xml = gReturn.getElementsByTagName("item");
    var l_ID = l_Opt_Xml.getAttribute('id');
    var l_El = html_GetElement(l_ID);
    if(l_Opt_Xml.firstChild){
    var l_Value = l_Opt_Xml.firstChild.nodeValue;
    }else{
    var l_Value = '';
    if(l_El){
    if(l_El.tagName == 'INPUT'){
    l_El.value = l_Value;
    }else if(l_El.tagName == 'SPAN' &&
    l_El.className == 'grabber'){
    l_El.parentNode.innerHTML = l_Value;
    l_El.parentNode.id = l_ID;
    }else{
    l_El.innerHTML = l_Value;
    get = null;
    //-->
    </script>
    HTML Form Element Attributes
    onChange="pull_multi_value(this.value)";
    For Riich Text Editor i have changed these value in Application Process and table column data Type
    v_mgr  clob;
    DESCRIPTION Column Type Clob
    How can i do this with Rich text Editor /
    Thanks                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   

  • Disable only one radio button in a Radiogroup using Dynamic Actions.

    Hello everyone,
    I'm using Oracle Database 10g Enterprise Edition Release 10.2.0.4.0 - 64bit with Application Express 4.1.1.00.23
    I have a radio group which has 3 radio buttons. Now in certain situations I want only one of the radio buttons to be disabled.
    I don't want to resort to Javascript for this as that would mean another piece of code that can go wrong and introduce bugs.
    Is this possible using a Dynamic Action? Although DA is also JS, I feel its much easier to maintain.
    Regards,
    Arijit

    I know, you did ask for DA
    Try to put this code in DA and run this code on page load
    =-==========================================
    var pOption = 3;
    var nameArray = $('input[name=p_v01]').map(function(){
                        return this.getAttribute('value');
                    }).get();
    for (i=0;i<nameArray.length;i++){
        if(pOption == nameArray[i]){           
            $("#P2_CHECK1_"+i).attr("disabled", true);
    ==========================================
    Plain Javascript
    <script type ="text/javascript">
    function disableCheckBox(pOption){
        var nameArray = $('input[name=p_v01]').map(function(){
                            return this.getAttribute('value');
                        }).get();
        for (i=0;i<nameArray.length;i++){
            if(pOption == nameArray[i]){           
                $("#P2_CHECK1_"+i).attr("disabled", true);
    $(document).ready(function(){
        var chkOption = 3;
        disableCheckBox(chkOption);
    </script>
    Thanks,
    Ramesh P.

Maybe you are looking for