Turn on the switch when a check box is selected in a report

Hello

I'll have a report with a box with the code column such as
apex_item.checkbox(1,"EQUIPMENT_ID") Tick,
EQUIPMENT_TYPE as "Device Type",
EQUIPMENT_NAME as "Device Name",
 CUSTOMER_NAME as "Customer Name",
 SITE_NAME as "Site Name"
 
  from DEVICE_VIEW
I have 2 buttons named "discover" and "Provision" in the same region of report. I want to activate the button when

at least one box is checked. How can I do this

Thank you
TJ

TJ,

It's to do with the JS. See this piece of code in above JS.

>

ARR = document. Forms [0]. F01

JS here made the implicit conversion. If your report returns multiple lines and then stop will become an array object, then everything works as expected. If your query returns a single row, Rios will be just an input arr.length element will be undefined.

So replace enableButton() JS code


See you soon,.
Hari

Published by: Hari_639 on September 27, 2009 13:59

Tags: Database

Similar Questions

  • updated in real time of the values when a check box is selected

    Hello
    I have a form with elements of the address

    Physical street address, physical city etc etc.

    I have also the same for address Street, city ett etc. on the same entry form

    I want to include a checkbox which when selected fills the values of the mailing list
    list physical values. The box would be as ' select this option if the update to the post office
    the address is the same as the physical address '

    I know how to do this with a process and send the page. May I, however, when the box is
    selected, or at least define the display attributes for read only for items in the mailing address of the box is activated?

    Thank you very much

    Steve

    Steve,

    No problem.

    $x is a wrapper for the APEX to document.getElementById () JavaScript; It's a heck of a lot easier to simply use $x vs the longer string. Please keep in mind that it will be only when you include the JavaScript libraries of APEX, which, by default, are included with each page APEX.


    What about a book, Yes, I can offer a: Pro Oracle Application Express (http://www.amazon.com/Oracle-Application-Express-Experts-Voice/dp/159059827X) Chapter 8 covers Ajax Javascript, & this is where I would start.

    There are also a lot of other online resources, including this Forum, that can help you learn how to use JavaScript & APEX.

    Thank you

    -Scott-

    http://spendolini.blogspot.com/
    http://sumnertechnologies.com/

  • JavaScript to display the output if multiple check boxes are selected

    Hello

    My PDF form has a number of questions about this, some of which are multiselect.

    for example

    Identify the colors of our company logo (there are three)

    Blue

    Red

    Green

    Orange

    Yellow

    Purple

    If they choose the good ones (blue, red and yellow), the script should display a 'Correct' output, if they look for something else, it should show incorrect. I have worked out how to do it for a collection of radio button, but may not know of check boxes.

    Any help would be greatly appreciated.

    Concerning

    I don't know, but see if it works for you: http://acroscript.net/pdf/demos/Adobe_Forums_1993380.pdf

  • Impossible to verify if the check box is selected

    I am trying to execute a JavaScript function that triggers, when a check box is selected.

    I have a problem, this function of packaging
    The condition that I am applying does not-
     if(document.wwv_flow.f01.checked == true) 
    I need to check only one box to check, not a table.

    Here is the code of the function:
    function boxesCheck3( cb ){
         if(document.wwv_flow.f01.checked == true){
            //do the job
                } else {
                   //do nothing
           }  
       }
    What is the problem with my condition?

    Thank you!

    Hello

    Try

    function boxesCheck3( cb ){
     if(cb.checked){
      var get = new htmldb_Get(null,$v('pFlowId'),'APPLICATION_PROCESS=VALIDATE_DELETE',0);
      get.addParam('x01',cb.value);
    
      gReturn = get.get();
      get = null;
      var aReturn=gReturn.split("|",2);
      alert(aReturn[0]);
      if (!aReturn[0].match(/^.*_OK$/)){
       alert(aReturn[1]);
       cb.checked=false;
      }
     }
    }
    

    Kind regards
    Jari

  • FN + F8--> 'wifi is not activated. Turn on the switch.

    Hello

    I reinstallled the Windows 7 64-bit recovery DVD and I noticed a problem which the utility Flash Cards do not work. So I downloaded the package of added value.
    Now Flash cards made its appearance, but when I press Fn + F8, I get this message: 'the Wifi is not activated. Turn on the switch! "

    SRY for the imperfect grammar.

    If you have a small switch WLAN on your laptop to the position we walk in first. After doing this using FN + F8 key combination.

    What model of laptop do you have exactly?

  • If choose something lower down then the check box is selected

    I want to choose from a list in the drop-down menu.  According to what is selected, then a box will be checked automatically.  This

    is what I have so far for the script.

    If (list == 'blah') then this.rawValue = 1

    I do not know if it to JavaScript or FormCalc... I guess JavaScript because there is no calculation.  I'm also not sure whether to put the script on the drop-down list or checkbox.  Also in which should case I use?

    Thank you

    Him == is used to compare two values. then you use it properly in the case. When yo want to assign a value to an object, then a unique sign = is used. So, your code should be CheckTwo.rawValue = 1.

    You can use an OR condition to check multiple values of th FEI statement. So if the box should be checked if they choose blah, blah2 or blah1 then you might do this:

    If ((this.rawValue == "blah") |) (this.rawValue == "blah1"). (this.rawValue is "blah2")) {

    CheckTwo.rawValue = 1;

    } else {}

    CheckTwo.rawValue = 0;

    }

    Make sure to uncheck the checkbox if none of these options are chosen. That way if they choose one of these options (the check box is selected), and then they change their mind and choose a different value it should be disabled.

    Make sense?

    Paul

  • Turn off the music when I plug into the speaker / earphone cord

    Turn off the music when I plug speake / headphones cord. Have to unplug to get the music to play again.

    Have you ever force reboot the phone by holding down the button sleep and home for 10 seconds, until the Apple logo comes back again? You won't lose data, but it can cure a few glitches.

    Usually the music stops if you unplug the headphones to the device, and you have to press 'play' again to keep listening via the external speaker.

    If you use the external speaker and plug in the headphones, the song doesn't stop and continues to play through headphones. Just tried it with my camera.

  • In the Pages, when I quand je selectionne selects open for a list of my files, all I get is an abbreviated list of a few files.  That's happened?

    In the Pages, when I quand je selectionne selects open for a list of my files, I get nothing more than a brief list files, more than other things.  What happened and how do I get my list?

    When you choose open, it will open the finder and you will find your way to all the files.

  • Total of a column when the check box is selected in table form

    Hi all

    Total of a column when the checkbox is enabled in the form of tables, but is not work, help

    https://Apex.Oracle.com/pls/Apex/f?p=82062

    My credentials for my worksapce:

    https://Apex.Oracle.com/pls/apex/

    Workspace: GB

    USERNAE: [email protected]

    PASSWORD; GB

    Thank you.

    abb.JPG

    abcd.JPG

    abcde.JPG

    Kind regards

    GB

    Hi user13028844,

    user13028844 wrote:

    Please change your login username of "user13028844" to something meaningful. Reference: Video tutorial how to change username available

    The second button is a javascript function call, which is not a summary. the javascript function has a problem

    This function has the problem help me correct, whereas we can summarize the amount of lines checked

    I have made changes to your page. Check the "Display of Javascript" button, now it shows the correct amount for active items.

    Made the following changes:

    • The following are removed from the section "run when Page Loads:
    Declare
      p_qty          number;
      p_total_qty    number := 0 ;
    Begin
    for i in 1..APEX_APPLICATION.G_F01.COUNT LOOP
      select nvl(qty,0) qty into p_qty from DURATION
        where id = to_number(APEX_APPLICATION.G_F01(i));
       p_total_qty := p_total_qty + p_qty;
    end loop;
        --htp.prn(p_total_qty);
    htp.prn('');
    apex_application.g_print_success_message := 'Checked total qty:'||p_total_qty  ;
    End;
    

    NOTE: The section "run when Page Loads" is intended for JavaScript code to perform the loading of the Page and NOT PL/SQL code.

    • The following code removed from the section "Header HTML":
    
    

    This code was going nowhere, so removed and replaced with code below.

    • Added the following code in the section "function and Global Variable declaration:
    function enableButton() {
        // code goes here
    }
    
    function total_checked() {
       var total = 0; var qty = 0;
       $( 'input[name="f01"]' ).each(function() {
         if ( $(this).is(':checked') ){
           qty = $(this).closest('tr').find('td[headers="quantity"]').text();
           total += parseFloat(qty);
         }
       });
       alert("Checked Total Quantity : " + total);
    }
    

    Your APEX_ITEM. BOX calls a JS "enableButton" function, but it has no definition, dummy definition so added.

    Kind regards

    Kiran

  • Reposition the cursor when the check box is selected

    Good day all.

    I'm trying to figure out how I can reposition the cursor in a text field once I've selected a checkbox.

    Example; I have 3 boxes can select use. When the user selects the check box, I want to cursor to move to this box.

    Does anyone know how this could be done?

    Using Adobe LifeCycle Designer 8.0

    Windows XP Pro

    Thank you all

    Chomp

    No Chomp problem, I updated the form that you posted to set focus in the first textfield in the hidden subform (criterion 1). I published the form here:

    https://Acrobat.com/#d=46bhrRPpzUOEN4XI7--W-w

    Notice how the full path should be clearly explained when fields bound, in this case, a check box and a text field, are in different subforms.

    If you never do know what the full path to a field, click a different field, click in the script Manager window, then ctrl + click the field you want the path. If you have this selected field ctrl + click 'this' will return just as he will himself reference in the script manager.

  • I can't turn off the display when I use screem saver

    I keep my laptop always on, recently the screem saver don't work when I choose when turn off the display. All this time, the show view screem saver, but never active the option off.

    Hello

    ·        Is there wireless devices connected to the computer when you leave it on?

    Wireless devices may also not allow the computer to turn off the screen if there is no interference.

    In addition, it is not advisable to keep the laptop. He could be an update or a facility that has occurred and which requires a stop. Would cause the problem; try to restart the computer and check if the problem persists.

    If the problem persists, check that the power plans settings. For more information follow the link below.

    http://Windows.Microsoft.com/en-us/Windows-Vista/power-plans-frequently-asked-questions

    Also, try to change the theme of the computer and check if that helps. to change the theme follow the link below.

    http://Windows.Microsoft.com/en-us/Windows7/change-the-theme-to-improve-performance

    Hope this information is useful.

    Amrita M

    Microsoft Answers Support Engineer
    Visit our Microsoft answers feedback Forum and let us know what you think.

  • HP Probook 645 G1: Turn off the wifi when it is connected to the wire

    Hello

    I have a HP 645 Probook G1 A4 - 4300 M / 4 GB / 500 GB SSD/DVDRW/14 "HD/W7P 64B latptop.

    I also have a model Dockingstation REPLACEMENT-I10X.

    I have attached an ethernet cable on the docking station that works. My problem is that when I connect my laptop to the docking station. Get a priority above wired wireless. If the laptop still uses wireless unless I turn it off manually.

    Ofource I want to log out manually. I want the phone choose wired when wired and wireless when wireless.

    I tried a couple things:

    1. I went setings adapter--> advance--> Advance settings--> moved the connection to the lan network to a network connection wireless, top of page bottem. it did not work

    2. I manual put several metrics in connection properties (internet protocol 4 & 6--> Properties--> Advanced--> change automatic metric to manual and filled a small number to wired connection (No. 5) and filled a higher number (No. 250) to the Wi - Fi connection.) it did not work

    3. looked in the bios menu. There is no option to change the priority or something like that.

    Now, I always disconnect the wifi when I'm attached to the docking station (even tried plugging an ethernet straight cable to the laptop, but that has not helped either). Problem is when I unlock the laptop from the docking station, I have to manually reconnect to the wireless network.

    Additional info: since my laptop is always closed when it is locked on the docking station, I cannont press the WIRELESS button to disconnect or connect.

    Any suggestions help would be greatly appreciated.

    Hello:

    See if the BIOS of your laptop computer has a LAN/WLAN, commissioning.

    On my HP Elitebook 6930p it is a parameter to enable the LAN/WLAN switch that automatically turns off the wireless card when an ethernet cable is connected, and vice versa.

  • Export the value zero (0) check box cleared?

    I have a form (Acrobat x) with checkboxes. I want to give rise to numerical values if checked or unchecked. I have this merged with other data and count the yes / no value is another problem. I did the exported value is 1.  If the checkbox is not checked 'No' has failed.

    Is there a way to make the value for a default value for the box unchecked to 0?

    Have you created the form in Acrobat or LiveCycle Designer? If Acrobat, the value of the field when disabled is 'Off' and it cannot be changed. If LiveCycle Designer, you should be able to set the value off to 0.

  • How to select the values for each check box in a group of records

    Hello

    I have a requirement in form 10g. In this form there are 10 records are display each record has a checkbox is there if I click on the check box save number one and number three and make some changes in the text field (field adjustment is the number data type) and then finally, I want to see the total a total amount called field.

    In this, my question is how to select specific to a group of records records? and finally these selected records are inserted in a table.
    Because I am not able to read these records at a time.
    Is there any table to define a record group to fetch each of them individually for example Rec [1] Rec [2]... like this if yes please suggest me the steps how to do this.

    Thanks in advance
    Prasanna

    Published by: user10315107 on December 17, 2008 23:44

    OK, so you want to shoe the total amount in the form itself (I guess that somewhere under the dashboard lines?).

    You can do this easily using formulat elements:

    1 create a new item in your block where the field amount is places, set "section of the database" on the 'No', 'calculation mode' to the 'formula' and the 'formula' himself to something like:

    CASE WHEN :BLOCK.CHECKBOXITEM=CHECKVALUE THEN :BLOCK.AMOUNT+:BLOCK.ADJUSTMENT ELSE 0 END;
    

    This formula returns 0 if the checkboxitem is not checked, otherwise the sum of amount and adjustment (of course you can adjust the names of elements and the value for 'Checked')
    2. place the element in the layout, if you wish.
    3. set the property "Query all Records" to "true" for your block elements, this is necessary for the calculation to work
    3 create a control block to keep summary article in a, "Single Document" set to 'True '.
    4. place a new element in this control block, set 'Calcuation mode' to 'Summary', 'Summary block' to your block elements, 'Summary point' in newly created formula section in the block elements
    and function of synthesis for the "sum".
    5. place the element in the layout

    She's.

  • How to turn off the "switch-to-tab" feature in the awesome bar?

    When I am a student I usually like to open several instances of a single page, and then direction out there, so the switch-to-tab function is incredibly annoying for me. I imagine that this solution is very simple, but I've been looking for quite some time now and just can't seem to understand.

    You can disable it by installing the switch for no tab no Add on more - https://addons.mozilla.org/firefox/addon/switch-to-tab-no-more/

Maybe you are looking for