Dynamic actions and tabular forms

I'm trying to attach a dynamic action to a tabular form item, and it's not working the way I'm expecting it to. Since you can't attach dynamic actions to parts of a tabular form in the "normal" way that you can for page items, I'm using JQuery selectors to pick the parts to link to. For links (such as opening a pop-up window with more information about a row), this is working fine. But I'm really struggling to attach to a simple checkbox.
On my tabular form, I've got a simple checkbox. I've tried putting text in the Element Attributes, Element Option Attributes, CSS Class, CSS Style, and HTML Expression fields, but none of them appear to be making it through to the source code of the generated page. Which means, I think, that I'm limited to using a jQuery Selector along the lines of "input[name=f07]", but creating a dynamic action on click or on change with that selector doesn't seem to ever fire.
What am I missing?
-David

Ok, this is interesting. When I tried to mock this up on apex.oracle.com, I was able to make it work (though I had to change the selector to "input[name=f07_NOSUBMIT]", which means I'm going to have to walk the DOM to get the actual value...but I'm pretty sure I can handle that). After a bit of scratching my head, I eventually found that my pop-up dynamic action was somehow or other blocking the checkbox dynamic action from firing. Changing the sequence so that the checkbox DA happens first allows them both to fire.
Here's the javascript from the pop-up DA (it's based on this post by Havard Kristiansen):
/* prevent default behavior on click */
var trgt = this.triggeringElement.href;
var e = this.browserEvent;
e.preventDefault();
/* Trigger JQuery UI dialog */
var horizontalPadding = 30;
var verticalPadding = 30;
$('<iframe id="modalDialog" src="' + trgt + '" />').dialog({
     title: "Item Details",
     autoOpen: true,
     width: 570,
     height: 400,
     modal: true,
     close: function(event, ui) {$(this).remove();},
     overlay: {
          opacity: 0.5,
          background: "black"}
}).width(570 - horizontalPadding).height(400 - verticalPadding);
return false;At this point, the checkbox DA's action is simply an alert box. Like I said, I'm not sure what's going on, but I'm at least able to move forward...
-David

Similar Messages

  • Dynamic Action on tabular form: to auto set value for all changes rows

    Hi All:
    I am using APEX4.2.3 and I am not very familar with JQUERY or Javascript.
    I am having a tabular form to support Update and Delete action. The tabular form has 4 columns:
    Column A: ID                      (Number)     : Read-only column
    column B: Name                 (Varchar2)   : Editable
    Column C: Age                    (Number)     : Editable
    Column D: ChangeFlag      (Varchar2)   : Read-only column                             ==> however, I want this column been automatically upldated by my APEX application
    Here is the requirement: First user update Column B, or C or both for # of rows; then user click "Save Change" button. For ALL updated rows, I need to automatically update Column D with below logic:
    For a given row,
                   IF Column D IS NULL  THEN
                         set value = 'M'                           -- M means modified
                   ELSE --- column D has a value already
                        IF last character of Column D is 'M', THEN
                               don't do anything;
                        ELSE
                              set value of D = existing value + 'M'                       (here + means concatenate
                       END IF;
                END IF;
    I thought this can be done by creating dynamic action on tabular form ... I have researched this on this forum and can't find a good match example ..
    I know I can implement this using a DB trigger; however, I want to learn if this can be achived via Dynamic Action.
    Thanks!
    Kevin

    Hi Expert:
    Anyone can offer any direction or help on this?
    Thanks!
    Kevin

  • Dynamic action on tabular form

    Hi all,
    I'm working on a page with a tabular form. Based on the value of a radio button group, some of the columns has to be hidden. I have some experience with dynamic actions, but not in conjunction with tabular forms. I guess I have to use a jquery expression, but that's another area I don't have any experience in...
    Can someone help me or give me some directions? I'm on Apex 4.1
    Tom
    Edited by: Tom van der Duin on 22-okt-2011 12:02

    Hi there,
    I am using Apex 4.0 and it seems to generate tabular forms like this:
    <th id="START_DATE" class="header"> headings
    <td headers="START_DATE" class="data" style=""> data cellsSo, you can use the Javascript code below to hide and show a column based on its name:
    function hideShowTabularFormColumn(name, show){
      if(show) {
        $("td[headers='"+name+"']").show();
        $("th.#"+name).show();
      } else {
        $("td[headers='"+name+"']").hide();
        $("th.#"+name).hide();
    onsomesortofevent="hideShowTabularFormColumn('START_DATE', false);"Note that, even hidden, the fields will still be submitted.
    Luis

  • Dynamic action on tabular forms fields

    Hello guys.
    As I can see on the tabular form's fields I can't perform dynamic actions. What I want is to have a select list item when at the event Change it changes the values for all the records in that report. For example if I have 40 records in that tabular form and I change the value from "Open" to "Close to the field called Status, I want to see that change (Status value from "Open" to Close") reflected in all the rows of that tabular form. Is that make sense?
    Thank you, Bernardo.

    Hi Bernardo,
    There are several ways to accomplish what you want.
    - You can create a PL/SQL procedure to handle an update on all rows based on the value of your changed column value. I once wrote a blog post that might help you with that:
    http://vincentdeelen.blogspot.nl/2013/06/custom-multi-row-processing-using.html
    -You can create a dynamic action with javascript or jQuery to handle the change event.
    The first option is more secure since it's handled by the database, the second one is simpler and can instandly set all the entire column for all displayed rows, without the need to refresh your tabular form, or your entire page. For a secure working you should however have some validation at the database end. Also I think it is not possible to set the values for rows that are not displayed, that again would require some PL/SQL for handling.
    If you need any help setting up the dynamic action, please put up an example on apex.oracle.com.
    Regards,
    Vincent

  • Dynamic actions in tabular forms

    Hi,
    i have 4 columns in tabular forms.
    emp_code emp_name emp_position emp_status
    whenever a user enter the emp_code
    the emp_name,emp_position and emp_status should be automatically displayed.
    i try to use dynamic actions to populate the emp_name , emp_position, emp_status.
    but i cannot identify which columns / item to use since its a tabular forms.
    can anyone help ?
    thanks
    regards
    jerry

    here's what you can do for your situation
    <li>Create an AJAX Callback process(PLSQL type) in your page that is similar to
    DECLARE
      lc_result XMLTYPE;
    BEGIN
       SELECT XMLELEMENT("COL"
                                     ,XMLELEMENT("COL1", wwv_flow.g_x01)
                                     ,XMLELEMENT("COL2", LPAD(wwv_flow.g_x01,10,'0'))
                                     ,XMLELEMENT("COL3", RPAD(wwv_flow.g_x01,10,'#'))
                                     ,XMLELEMENT("COL4", 'blah blah')
                                   ) RESULT
      INTO lc_result
      FROM DUAL;
        OWA_UTIL.MIME_HEADER('text/xml', false);
        htp.p('Cache-Control: no-cache');
        htp.p('Pragma: no-cache');
        OWA_UTIL.HTTP_HEADER_CLOSE();
        htp.p(lc_result.getstringval());
    END;This returns an XML with the rows data. I have just used some simple processing of the input data in this case, but you can modify it for your need
    <li>Then have a Dynamic Action that is triggered on change of the f01 input field
    //value of triggered item
    val = $(this.triggeringElement).val();
    //Call Ajax Callback process
    var a = new htmldb_Get(null,$v('pFlowId'),'APPLICATION_PROCESS=FETCH_ROW',$v('pFlowStepId'));
    a.addParam('x01',val);
    X = a.get('XML');
    //Obtain data from returned XML
    col2 = $(X).find('COL2').text() ;
    col3 = $(X).find('COL3').text() ;
    col4 = $(X).find('COL4').text() ;
    //Set items
    this_row = $(this.triggeringElement).parents('tr:first');
    this_row.find('input[name=f02]').val(col2);
    this_row.find('input[name=f03]').val(col3);
    this_row.find('input[name=f04]').val(col4);This sends the f01 field(triggering source) to the PLSQL that returns the data in XML format for 3 other columns and sets those columns.
    Hope that answers your question.

  • Dynamic Actions on tabular form items

    Has anyone had success with using dynamic actions on a tabular form item?
    When I create a dynamic action for the selection type I believe I want to use DOM Object, I am just not sure what ID I then need to put into the DOM Object field.
    Any help would be greatly appreciated
    Regards
    Mark

    If you wish to use JavaScript with tabular forms, I suggest looking at APEX_ITEM column types. They allow you to specify the JavaScript array number of any given column in your tabular form and rely on it. Then as you loop through your rows you can positively identify the element.
    Example:
    Original query:
    select colA, colB from myTable;
    select apex_item.text(1, colA, 20,20) as myText,
      apex_item.select_list_from_lov(2, colB, 'LOV_MYLOV', 0, 'NO') myLookup
      from myTable;I also highly recommend Firebug for Firefox. It will allow you to drill down into the DOM on any page to see the element identifications as the browser sees them. Definitely the best browser plugin for web development.

  • Dynamic actions and PA-PD integration a problem

    Are you aware of an update problem with MSS and PA-PD integration?  This information was made available in a presentation to us last year.  Was this issue resolved in mySAP ERP 2004?
    Dynamic actions and PA-PD integration a problem
    Dynamic actions and PA-PD integration are not
    processed on updates made from the web (but in the
    background through a batch or call transaction session)
    That’s why most standard PCRs require HR to process
    the transaction using the SAP GUI in the foreground
    This normally affects changes to infotypes 0000 &
    0001
    Then the next slide states:
    Workaround for dynamic actions
    Review dynamic actions in table T588Z (use SE16 to
    display) and document the infotypes and values that
    trigger dynamic actions
    Incorporate those infotypes into your background
    processing and web forms (if necessary)
    Workaround for PA-PD integration
    Include the integration steps for these infotypes in your
    background processing (just as in conversions)

    Hi John,
    Not sure if it is fixed.. or can be fixed.. we are still in 47  & Use custom code to account for Dynamic Actions.. the PCR processes use the function module HR_MAINTAIN_MASTERDATA to update the infotypes. This function mimics a BDC & hence cannot handle Dynamic Actions... Basically, the issue is not with MSS but it is the way Dynamic Actions work.. to quote SAP  "Dynamic actions are not correctly processed in batch input sessions since in batch input the sequence of the screens needs to be predefined correctly. To be able to process dynamic actions in batch input, the checks of the dynamic actions need to be programmed when creating the batch input session. To avoid errors when programming and running the session, the static actions  only are processed in batch input. Calls of infotypes that are triggered by dynamic actions should be realized by separate Transaction calls.
    Please take a look at OSS Note #386027 for additional info about Dynamic Actions.
    Regards,
    Suresh Datti

  • Source tables for forms and tabular forms must have a primary key.

    Why does HTML DB 2.0 return the message
    "Source tables for forms and tabular forms must have a primary key."
    when trying to generate a "Report and Form" page based on a view defined like "create view <applicationschema>.a as select * from <sourceschema>.b" ?
    It should be possible for HTML DB to "see" that the table "<sourceschema>.b" already has a primary key.
    bw - Christian

    Christian,
    In the create application wizard, when creating form or tabular form pages, you can only use tables with primary keys, and not views, because that wizard is automatically deriving the primary key from the table definition. If you want to build forms on views or tables without a primary key, you need to use one of the create form wizards while working on an existing application. Those wizards allow you to pick your own column as a primary key column.
    Regards,
    Marc

  • Difference between dynamic actions and user exit

    Hi,
    Please help me in when to use table T588z and user exit to write code for dynamic actions.
    Thanks,
    Venkat

    Hi Prasad,
    Find the difference between Dynamic action and user exits.
    Dynamic Action                                              User Exits
    1. Here only initialization of an infotype                    1. Along with initialization of an infotype,                  depending upon other infotype                                    validation also can be done like in
        can be done.                                                        IT 16 the contract end date can not be
                                                                                    entered more than 6 months.
    2. Less time consuming to write.                             2. Require programming approch so more
                                                                                    time consuming.
    3. Table T588Z                                                       3. PBAS0001
    Br/Manas

  • Dynamic LOV FOR TABULAR FORM 6i

    Hi,
    I have tabular form of two Items(ID,DESC) and I want to Populate LOV for item(ID) every record
    and record_Group & SQL statments are stored in DB.
    ACTION: when query in POST-QUERY Trigger get for every record in tabular form -- the stored SQL-Statment from table then put it into dynamic record_group and populate the dynamic LOV.
    Please advice,
    Thanks in Advance.

    OK daniel
    This form used for get reports
    then header get the name of Report (Table-A) (report_ID),(report_desc).
    then details for get the Parameters will send to report builder (Table-B) (detail_id),(report_id),(sql_stm).
    so parameters may be need for example stock code so this record need to query from stocks table to get stock code and stock name.
    next record for item Code so need to query from Items table to get the Item code and Item name
    another report for employees so the user enter report code then when query and get in details block employee code and employee name.
    so the lov will check if this record have query sql-statment or not if have execute it in the record_group then in lov
    then go to the next record if sql_stm is null then no lov in this record and so on.
    thanks..

  • Dynamic Lov in Tabular form

    Hi,
    I'm creating select lists in tabular forms
    and 2 select lists in it.
    I'd like to use 1st list as a filter of 2nd list dynamically.
    How can I do that?
    Please advise me.
    I found one tips(http://htmldb.oracle.com/pls/otn/f?p=18326:54:10017106699293281168::::P54_ID:1282) and I tried to do it but it didnt work...
    Thanks

    Hi,
    There's several postings in the forum on how to do this, so if this message doesn't make sense, search the forum some, maybe for my Name?
    If I remember correctly, using the following as an example, to something similar. This is based on a country and state lookup.
    field 1 (:P1_country):
    select distinct country from lu_location;
    field 2 (:P1_state):
    select distinct state from lu_location
    where country = :P1_country;
    Make :P1_country a 'Select List with Submit', and it 'should' work. I'm at home, so I don't have access to my database.
    Bill Ferguson

  • Insert Dynamic Action of a Form is not working

    Hello
    I've designed a form and some ratio buttons and some other items. A button fires a dynamic action, first with a submit page true action and then with an insert statement action. The button submits the page too.
    Sometimes the values of the form are inserted into the database correctly, but several times not. A new row is created every time, but in some case with no values in the columns. I tried several configurations but I couldn't find out what the problem is.
    Is there a common reason for this issue?
    Regards
    Felix

    I now found a box in the insert dynamic action saying "Page Items to Submit". I added all Items there and now with three times page submission it now works. Or at least it works according to my testing.
    Regards
    Felix

  • Can we have Manual Form and Tabular form in the same page..

    Hi,
    Is it possible to create a form manually with Save/Apply Change button and another Tabular form using wizard on the same page such that -
    if we click the save button on the manulaly created form , it should save the data present in manual form as well as Tabular form...
    Edited by: Apex_Noob on Mar 21, 2009 5:58 AM

    Hi Dan,
    My table structure is :
    Process
    process_id ( number primary key )
    process_owner ( number which represent the user who is responsible for the process)
    category_id ( number )
    focus_area ( number )
    frequency ( number )
    process_description ( varchar2 )
    Process Region
    process_id ( number )
    region_id ( number )
    Process_website
    id (number primary key)
    process_id ( number)
    web_address ( varcahr2 )
    Above is the struct of part of my DB.
    At present my manual form does the following :-
    When users click on SAVE button , it run PAGE PROCESS , ADD_PROCESS
    In ADD_PROCESS ,
    I have following logic to insert into process table
    Select seq.next_val into temp_variable from dual; - This is the process_id
    insert into process values ( temp_variable , :p2_process_owner , :p2_cateogory , .... )
    to insert into region i used the following logic ( Region is displyed as check box :p2_region north=1 , south=2 ,east = 3 and west = 4)
    l_vc_arr2 := APEX_UTIL.STRING_TO_TABLE(:P2_REGION);
        FOR z IN 1..l_vc_arr2.count LOOP
           INSERT INTO "REGION" VALUES
           ( temp_variable ,
             l_vc_arr2(z));
        END LOOP;
    END;Now as I told, I want to have three text field where user will enter web_address and it should be added to process_website table
    Thanks a ton for all your help
    Regards,
    Shijesh
    Edited by: Apex_Noob on Mar 21, 2009 10:07 AM

  • Workspace Manager and tabular forms

    Does anyone know whether it is possible to use Workspace Manager with tabular forms using APEX's multi row processes?
    I tried creating a process that runs before the multi-row processes that uses gotoWorkspace() to switch to a different workspace and another process afterwards that switches back to the LIVE workspace. However, the changes go into the LIVE workspace rather than the desired workspace.
    Rodney

    Turns out my application did indeed need to be debugged. I had an explicit condition written to limit the process to certain buttons, but I also managed to add an unintended constraint that the process only run when the Add button was used. The result was that the process ran, creating a workspace, when one added a row, but didn't switch back to that workspace when one saved the new row.
    Sorry for the false alarm.
    At least I can confirm for anyone considering this option that APEX does work with Workspace Manager as long as you can enable the versioning on the tables through another means.
    Rodney

  • I have developed a little tool to help with Dynamic Tabular Forms....

    I have created a little framework which will help people to develop dynamic actions in tabular forms.
    It currently only supports text and display only but if necessary I'm willing to expand this little tool...
    You can find it here: http://linuxservernico.no-ip.info:8888/JSON_Tabular_form.zip
    Please let me know of what you think about it and how to improve it...
    To be continued,
    Nico

    The problem is that APEX doesn't support dynamic actions and plugins on a tabular form (not yet).
    For now my implementation is just on overloading of the apex_item implementation of apex.
    Check the readme.txt for installation it isn't that hard but you need to understand the context.
    Thnx for the positive response
    Br,
    Nico

Maybe you are looking for