Tabular with LOV PPR and popup errors

I have a tabular presentation with several fields, which uses a value of selection as part of its sql source list.

The fields are popup lov is that there are too many options for a selection list has.  While these work very well by default, so enable partial-page refresh in the form of tables and add a dynamic action for when the selection list is changed to refresh the form, whenever I try and add a new line of the window popup lov throw errors javascript 'object expected '.

Someone else has come across this or know of a workaround?

The apex is 4.2.5


See you soon

Have not met before, probably because usually I avoid discounting on tabular forms.

But some research, I believe that what is happening is completely normal.

When the page loads everything first, the init of the widget in a table row contains the javascript function calls. This means that the various manipulations on the plain text of it will also handle content of the script (and name etc.). What causes more functions to create the lines are created, as a function in the global scope is created for each line and each element.

However, when page html code is retrieved on the server is placed in the document jQuery.html () - which "eats" the script tags and. After the update, the init line is reset. Because without script tags are present more that no function or is created. Where a javascript error because a nonexistent function is called.

Note however, that this works when you add new rows in an index position that a line of work previously. In your case, if after the initial page load, you need to add a line, and then use the select that triggers the update, add a new line again no will cause an error. Features are created in the global scope, so they keep existing.

Workaround solution? Yes, okay. Ugly as hell, but what is the source.

1 / get elements of the last row lov

2 / check these points if the associated function already exists

3 / if not, go get the original function, discussed in the text, do replace it and add it to the global scope

Add this to the declarations of functions and global variables:

Only works for apex 4.2 AND a wizard generated in a table (not apex.item!)

function myAddRow(){
  apex.widget.tabular.addRow();

  var lRowNum = apex.widget.tabular.gNumRows + apex.widget.tabular.gNewRows;

  $("#"+apex.widget.tabular.gTabFormReportID+" table.uReport tr:last span.lov input[type=text]").each(function(){
  var lName = $(this).attr("name");
  var lCheck = window["genList0_"+lName+"_"+lRowNum];
  var lOriginal = window["genList0_"+lName+"_$_row"];

  if ( typeof lCheck !== "function"){
    var lOld, lNew;
    lOld = lOriginal.toString();
    lNew = lOld.replace(/_0000/g,'_' + apex.widget.tabular.pad( ( lRowNum ), 4 ) );
    lNew = lNew.replace('p_element_index=" +  escape (\'0\')','p_element_index=" +  escape (\'' + ( lRowNum )+'\')');
    lNew = lNew.replace(/\$_row/g,( lRowNum ) );
    console.log(lNew);
    eval.call(window, lNew);
  };
  });
};

Change the button Add line to now call "apex.widget.tabular.addRow ()" but do call "myAddRow()".

Tags: Database

Similar Questions

  • Defective boot to a black screen with white cursor and DDDP errors.

    I have a Pavilion h8-1020, which began to show a black screen with a cursor flashing after the initial splash screen.

    I ran all the options except a complete reset utility mode.  I downloaded the Dell Diagnostics Deployment Package and booted from it.

    I ran the tests and got these errors

    4 c 00:0522 - system Interrupt controller or device has failed

    These all failed

    4600:021E - SMBIOS unidentified LM78A

    4600:021E - Fan1 SMBIOS

    4600:021E - SMBIOS chip fan 2

    I put an old HD and it starts to boot to the operating system while it recharges.  It is further than he gets with the original drive.

    Any thoughts would be appreciated.

    Thanks, BC.

    It's the Dell forum, so why you post questions on a computer HP here?

    The Dell diagnostics probably will work correctly with the HP hardware so that the results are meaningless.

    Ask your questions on the HP forum...

  • Win 7 will not update with 9 59 and 643 error Codes

    Were you able to copy and paste all command at the command prompt? It is normal that FORFILES to have a/c more than once as long as the other/c is contained in the order framed by double quotes.

    If in case you weren't able to copy the entire command, there is a possibility that he will not run.

    See screenshot below for the examples provided by the Forfiles command:

    Please repeat the steps listed above and an update on how it goes.

    Any new ideas?

    Please consider running Disk Cleanup, "Cleaning Windows Update" option. This operation requires a reboot that you won't be prompted to enter.

    Best regards, VZ

  • problems with customization select lists and popup LOVs

    Hello


    I have 2 problems on selection lists and popup LOVs.

    The first is on a list in tabular form.
    It must be created with APEX_ITEM. SELECT_LIST_FROM_LOV or similar and take its values of a named LOV.
    This worked fine, but now it should also have the possibility to enter a free value.
    I tried to accomplish this by creating an APEX_ITEM. POPUP_FROM_LOV, but there is a problem with the function which is called the icon of the right arrow to the input field (for eg. genList_f11_5()).
    If the line is added by addRow, then it works fine, but if the line is not empty
    Then the function call is as genList_f11_$ _row () and the input field becomes worthless, when an LOV is selected.


    The other problem is on a list of selection that should have the opportunity to enter a custom value and
    It should also be able to select multiple values. I tried to implement this in a text box that contains the selected values, and a multiple select list, with an event handler in each option. The user can click on options and they would be copied into the text box. The problem is that I couldn't make the event handler works in Internet Explorer.

    I would like ideas on one of these problems.



    Tiina

    Hello

    It can be created at APEX_ITEM. TEXT.
    APEX_ITEM also generates the name attribute that I use the jQuery selector in the sample.
    Use jQuery UI autocomplete just similarly as in my example with APEX_ITEM

    Kind regards
    Jari

  • Got a 27 "monitor from Apple, with thunderbolt (error). My MacPro can't love at first sight. Apple won't bring back the monitor. Will using a USB 3 map and then using a hard drive with USB 3 and Thunderbolt works?

    Got a 27 "monitor from Apple, with thunderbolt (error). My MacPro can't love at first sight. Apple won't bring back the monitor. Will using a USB 3 map and then using a hard drive with USB 3 and Thunderbolt works?

    N ° you need a computer logic board which has built in Thunderbolt.

  • Cannot change PopUp LOV width and height in version 4.2.5.00.08. I change the values of 450 400 in the Popup list template values (Section of the window), but my function genList0_f07_$ _row (), retains the same settings. Is this a bug?

    Hello

    I use APEX 4.2.5.00.08 to my app.

    I have a region of reports, where I display a column set. A column is the column attribute "display as" the value 'Popup LOV (LOV based query).

    I press the button to retrieve the LOV, I get a popup of 450 x 400 pixels.

    I go to the side of the model and navigate to "Popup list of values of model", where I can see in the section 'Window' attributes 'Width' and 'Height' value 450 and 400. I edit them and save them and there is nothing going on. I'm sure that the template belongs to my selected theme.

    I saw in the HTML source code that is the called function:

    <!--


    function genList0_f07_$ _row)
    {
    w = open ("wwv_flow_utilities.gen_popup_list" +)
    « ? p_filter ="+
    "& p_name = ' + escape ('f07') +.
    ' & p_element_index = ' + escape ('0') +.
    ' & p_elem_id = ' + escape ('f07_0000').
    ' & p_form_index = ' + escape ('0') +.
    ' & p_max_elements = ' + escape ("") +.
    ' & p_escape_html = ' + escape ("") +.
    ' & p_ok_to_query = ' + escape ('YES').
    ' & p_flow_id = ' + escape ('114') +.
    ' & p_page_id = ' + escape ('100201') +.
    ' & p_session_id = ' + escape ('16021544706004').
    ' & p_eval_value = ' + escape ("") +.
    ' & p_translation = ' + escape ('NO') +.
    ' & p_lov = ' +.
    ' & p_lov_checksum = ' +.
    ' & p_item_id = ' + escape('-683997768') +.
    ' & p_column_id = ' + escape ('25022622060292812'),
    "winLov,"
    "Scrollbars = 1, resizable = 1, width =400, height =450"); "
    If (w.opener is nothing)
    w.opener = auto;
    w.Focus ();
    }
    ->

    I see that the values has not changed. I also connected and disconnected. I am inclined to believe that it is a bug of the APEX.

    The only solution I think is to replace this function, which is NOT ideal.

    Thank you

    Digital

    The parameters are generated only, nothing you can do about it because it does not use the model for these properties of the couple. Other things work fine for example the names of button or title window etc. I guess that, Yes, it is a bug. It's still there in the apex 5 too, I checked. The default values of the template do not match, the value in the generated code is always 400/450. So I guess it's pretty much a wait on 5.1.

    Here's a fun hack to make it work well on your page (works in apex 5 too, because the code is always the same). Put this in the execute on loading of the page section:

    (function(){
      var _open = window.open;
      window.open = function(){
        if ( arguments[1] === "winLov" ) {
          arguments[2] = "Scrollbars=1,resizable=1,width=500,height=700";
        };
        return _open.apply(window, arguments);
      };
    })();
    

    Change the settings to your liking. This will replace the existing window.open call, which is what the popup lov use and replace it with our own code. It does not interfere with other things. As the name of the new window is always "winLov" for the popup lov, it is the argument that is checked.

    During the call to window.open to open a new window with the name "winLov", parameters are replaced with your own version of it. The window is called as usual, using the stored reference.

    Edit:

    Yes, do not use the trick of resizing. My hack can be a bit tedious, but it's much less invasive for the end user (see open, bam, resize. "Even gets funky on multiple monitors). Also, this thing in the popup lov template will affect each lov popup that you use in the application, which is much less interesting than my specific page code.

    Edit2:

    I did a little digging in the source code, and I don't know why it does not work. Popup lovs are actually equipped to deal with it. My guess is that the parameters are recovered only after that the lists were generated, causing the package variables global to use their default values instead of model parameters.

  • I want to go back to the previous version of 2014.2.  .3 is far too buggy and full of error messages. Create problems because I'm on a timeline with my client and I don't have time to fool around with all the problems.

    2014.3 is far too buggy and full of error messages. Create problems because I'm on a timeline with my client and I don't have time to fool around with all the problems.

    You don't mention what you have encountered errors? Workaround for the problem more frequently reached here is Re: error in Muse: object UID:U6875 has two (or more) owners: U3633 and U3165

    If you have a copy of your .muse file that has not been saved by using 2014.3, you can downgrade by uninstalling Muse, and then choose the previous Version in the drop-down list of filters in the Panel of Apps from the desktop creative cloud application. There will be a popup next to the Muse, where you can select a version prior to install.

  • Using SQL Server with ADF BC and getting Houston - 29114 ADFContext aren't Setup error

    Hello... I work with ADF BC and my connection is with a MS SQL Server database.  I added the sqljdbc4.jar in my template project, and can't seem to connect with the DB and build an Entity/View/AppMod infrastructure.  However, once I deploy the application on the integrated WebLogic Server I get errors when ADF BC tries to connect.  I added a POJO supported data control and tried to debug but PPR reports an error when my key to call the code stripped of JDBC:

    Houston-29114 ADFContext is not configured to process this exception messages. Use the code of exception stack trace and error to investigate the root cause of this exception. Root cause error code is Houston-29000. Error messages settings are {0 = java.lang.NoClassDefFoundError, 1 = com/microsoft/sqlserver/jdbc/SQLServerException}

    ADF_FACES-60097: for more information, see the error log of the server for an entry beginning with: ADF_FACES - Exception during the PPR, #1 60096:Server

    Seems to me that the POT is not in the classpath on the WLS.  What is the problem? If Yes... How would have added that JAR, sqljdbc4.jar, the path of the WLS class.  I've done through the deployment of models, and he saw in the META-INF/lib directory that has been deployed.

    Thanks for any help!

    Do not apply the JDBC JAR (s) in the archives of application deployment. You must add the JAR to the classpath WLS JDBC (s). Change the commEnv.cmd/sh for this script:

    Using JDBC with WebLogic Server - 11g Release 1 (10.3.6) drivers

    Note that WLS is pre-configured with a number of brand WebLogic DataDirect JDBC drivers (including a SQLServer driver), so you can use it instead of adding a new driver if the DataDirect driver meets your needs:

    Using WebLogic brand DataDirect drivers - 11g Release 1 (10.3.6)

    WLS 10.3.5 documentation provides more detailed information:

    The MS SQL Server driver

    Dimitar

  • After downloading the update for Yosemite 10.10.5, I got an annoying popup with a beep sound blaring that says that Safari crashed. I've forced to leave Safari, rebooted and popup returned once more. Restarted again and popup went. What was it?

    After downloading the update for Yosemite 10.10.5, I got an annoying popup with a beep sound blaring that says that Safari crashed. I've forced to leave Safari, rebooted and popup returned once more. Restarted again and popup went. What was it?

    Open Safari while holding the SHIFT key

    Try to reset the settings of Safari:

    1. open Safari

    2. click on the Safari menu at the top (to the right of the Apple logo)

    3. Select the Preferences/Privacy tab

    4. click on remove all data from the Web site

    5. close Safari.

    Remove cache Safari files:

    1. click on finder

    2. look for the menu GO to top

    3. click on GO and hold down the option key. This will show a user library folder.

    4. click library and find the Caches folder

    5. in the folder caches com.apple.Safari Ouvrezledossier

    6. move the Cache.db file Trash.

    This should solve the problem. If it does not help, try to disable the Safari extensions

    1. open Safari

    2. click on the Safari menu at the top (to the right of the Apple logo)

    3. Select Preferences

    4. find the Extensions tab

    5 disable all extensions of

    6. relaunch Safari

  • I try to sync a new phone 6 s with tunes11.4 and receive an error message saying that the phone unusable because it requires a more recent version of the air.  can anyone help?

    I try to sync a new phone 6 s with tunes11.4 and receive an error message saying that the phone cannot be used because it requires a newer version of itunes.  I've updated the phone and itunes.  can anyone help?

    Sorry, iphone and itunes.

  • I have created a new domain with win2012r2 and created users. Add after the client in my area so that the newspaper with the user I get error below.

    Hello

    I have created a new domain with win2012r2 and created users. Add after the client in my area so that the newspaper with the user I get error below.

    "You cannot connect because the logon method, you use is not allowed on this computer, please, see your ad min for more information network"

    Please help me with that and I don't want to give permission to admin for all users group...

    Hello

    Post your question in the TechNet Server Forums, as your question kindly is beyond the scope of these Forums.

    http://social.technet.Microsoft.com/forums/WindowsServer/en-us/home?category=WindowsServer

    See you soon.

  • error 87002efe on new computer with windows 7 and ie8

    Just got the computer with windows 7 and ie8 has tried to get the updates and get error 80072efe, cannot get updates. Also computer throws me off internet saying no link, but I hit refresh, and I'm immediately. Help

    1. download the Norton Removal Tool, save it to your desktop: ftp://ftp.symantec.com/public/english_us_canada/removal_tools/Norton_Removal_Tool.exe

    2. close all open applications (that is, anything with an icon on the taskbar).

    3. click right on the file saved in #1 above, and then select run as administrator to run the utility. DO TAP not your keyboard until the race ends, then restart.

    4 test cycle.

    ~ Robear Dyer (PA Bear) ~ MS MVP (that is to say, mail, security, Windows & Update Services) since 2002 ~ WARNING: MS MVPs represent or work for Microsoft

  • What is PXE - 61 media test failed error and the error PXE - MOF? What is the solution for this error? It's a lenovo with windows desktop

    I have a lenovo computer. I began as routine but unfortunately it says error:-what is media test failed error PXE - 61 and the error PXE - MOF? What is the solution for this error? It's a lenovo with windows desktop computer? How do I prevent this.

    Kala

    Hello Mohan,

    ·         You did changes to the computer before the show?

    These errors often occur if there are incorrect BIOS (Basic Input\Output System) settings.

    Method 1: Check if the computer startup options are changed in the BIOS. You can set the hard drive as the first boot device. In addition, make sure that this option "Wake on LAN" or one similar to it is off.

    Method 2: Load default BIOS (Basic Input\Output System) settings, and then restart the computer.

     

    Important : Change/update BIOS can be a complicated process, and if an error occurs, your computer could be rendered inoperative. Be sure to observe the instructions of the manufacturer.

  • Cannot perform updates of Windows with 641 and 80070641 error codes

    Original title: update problems

    Get 641 and 80070641 errors every time I try to download updates.  How to solve this problem?

    Hi Bob,

    Please follow the links:

    Method 1:

    I suggest to ignore the title and follow the steps as indicated in the article.

    0x80000FFFF error code when you download updates on a computer running Windows Vista by using Windows Update or Microsoft Update

    http://support.Microsoft.com/kb/946414

    Warning: Important This section, method, or task contains steps that tell you how to modify the registry. However, serious problems can occur if you modify the registry incorrectly. Therefore, make sure that you proceed with caution. For added protection, back up the registry before you edit it. Then you can restore the registry if a problem occurs. For more information about how to back up the registry, click on the number below to view the article in the Microsoft Knowledge Base:

    http://Windows.Microsoft.com/en-us/Windows-Vista/back-up-the-registry

    Method 2:

    Scan your computer by using the Microsoft Safety Scanner by clicking Download now, because this might have caused by viruses:

    http://www.microsoftsafetyscanner.com/

    Note: The data files that are infected must be cleaned only by removing the file completely, which means that there is a risk of data loss.

    I hope this helps.

  • Error occurred in making the disc of recovery with Dell backup and recovery

    Mr President.

    When I was doing a System recovery DVD with Dell backup and recovery when all steps were completed and finally when he was checking the disc a dialog box appears showing "AN ERROR has OCCURRED". How to get rid of this error?

    Please answer fast. Any suggestions will be appreciated

    Thank you

    Hey Himanshu Teli,

    Please provide the model of your operating system and Dell. I would also recommend that you try a flash instead of a DVD disc.

Maybe you are looking for