Dynamically hide show Page elements

Dear all,
Im tring to dynamically hide and show the page element. I searched and found something but it does not work for me. IM using apex 4.1 and below are described the work I've done.

I have 5 fields iitems in my page (form).

-The Customer No.
-Edit
-First name
-First name
-Address

I want to hide the name, surname, address, based on the value to change. Let's say if the user selects "name Edit" then name must obtain visible while name & address hidden.

So I put this line onChange = "$f_Hide_On_Value_Item(this,'LASTNAME,'LN')" in the point EDIT page > Label > HTML table cell attributes "

But it does not not for me? Where am I wrong?

Thanks in advance.

Have you seen the documentation? http://docs.Oracle.com/CD/E23903_01/doc/doc.41/e21676/javascript_api.htm#CHDHIAJB

I suggest you to use actions Dynamics http://docs.oracle.com/cd/E23903_01/doc/doc.41/e21674/advnc_dynamic_actions.htm#HTMDB27020

Tags: Database

Similar Questions

  • Hide/show pages

    I created a page of 5 forms using buttons to navigate to different pages. When the form is opened, you can navigate using the buttons, however, you can also scroll down and see the other pages how to hide these pages? The code I'm ising is the following:

    / which calls the function to hide all pages

    pageNav.hidePages ();

    This shows the target page again

    Page1.presence = "visible";

    Form1.Page1.navButtons.Button2::click - (JavaScript, client)

    that calls the function to hide all pages

    pageNav.hidePages ();

    This shows the target page again

    Page2.presence = "visible";

    Form1.Page1.navButtons.Button3::click - (JavaScript, client)

    that calls the function to hide all pages

    pageNav.hidePages ();

    This shows the target page again

    page3. Presence = "visible";

    Form1.Page1.navButtons.Button4::click - (JavaScript, client)

    that calls the function to hide all pages

    pageNav.hidePages ();

    This shows the target page again

    page4. Presence = "visible";

    Form1.Page1.navButtons.button5::click - (JavaScript, client)

    that calls the function to hide all pages

    pageNav.hidePages ();

    This shows the target page again

    page5. Presence = "visible";

    I thought about it, since I was still working on some pages that I had not changed and "hidden (exclude the layout). Thank you.

  • According to the selection value hide/show page list item

    Hi all
    I have a list of selection P_X (with Char, varchar2, number values).
    When I select the tank it must display P_Max (text box), if I select the number he must display two textboxes (P_Text1, P_text2).
    By default it should not display any page except P_X element.
    How can I achieve this by creating dynamic actions.
    I tried a dynamic textbox P_max display action when I click the Char value in the select list (P_X)

    After presenting the process:
    Start
    : p_x: = "Char";
    end;

    Condition:
    Value of exp1 = exp2
    Exp1:P_X
    EXP2:char

    dynamic action:
    event: change
    Select the type: article
    product (s): p_x
    condition: equals
    value: Char
    Real action: see question: p_max

    But it is not workking correctly.

    Hi Karthikeyan,

    Sorry for the late reply, stuck with another work.

    Now you check in your example I changed it accordingly. According to me, he answered your question, check in.

    Kind regards
    Mini

    Brand responses appropriately.

  • Problem with dynamic change a page element value

    Hello

    I just calculated dynamically the value of an article based on a simple formula which involves the multiplication of two elements of the same page.

    To do this, create a dynamic action as follows:

    Event: Change
    Selection type: Article (s)
    Product (s): P19_DURATION
    Action: Set value
    Fire on page load: TRUE
    Type of value: SQL statement
    SQL statement: SELECT: P19_DURATION *: DOUBLE P19_RATE
    Items to submit page: P19_DURATION
    Selection type: Article (s)
    Product (s): P19_AMOUNT

    When changing the P19_DURATION GET no change in P19_AMOUNT

    As my knowledge of javascript is almost zero, I'm doing it with pl / sql or sql. Try dynamic action with a function or a PL / SQL statement and nothing works.

    Must use javascript for this?

    Searching the forum I think that it is something simple, but I can't find a similar example to what I need.

    Concerning

    Event: change
    Selection type: item (s)
    Product (s): P19_DURATION
    Action: Set
    Fire on the page loading: TRUE
    Set Type: javascript
    JavaScript Code:

    amount = $v('P19_DURATION') *  $v('P19_RATE');
    $s('P19_AMOUNT',amount);
    
  • Hide/Show Pages based on the drop-down list selection

    Hello

    It drives me crazy. I have 3 boxes in this form (attached) and based on what is checked, I want to hide the first page and navigate to the 1st box checked. It works for the Web Chat feature, but others do not. In addition, the button following Web Chat page, when I click Next, I have a pop alert that should show only if Web Chat is the only selection, but it shows little matter how many selections are made from the boxes.

    As always, any help is appreciated!

    Hi, check if it works properly now.

    Dallas

  • Using JavaScript - hide/show a page element

    Environment:

    APEX 3.1.00.09 on AIX 5.3

    Sample application on apex.oracle.com:

    Workspace: GALWAY
    Username: gwicke
    Password: gwicke

    To see where my questions are:

    1 - Start on page 3
    2. in the Agency drop-down select 'J & B Marketing'
    3. in the contract drop down select the only contract that appears
    4 - Click "modify existing contract.
    5-note the "LY closures" page element has the value 261
    6 - click on the link (really a tab in my theme) at the top labeled 'full cost '.
    7 - the "Justification for estimate" is the page element to be displayed/hidden which is noted below.
    8 - "houses by year" under the column "Year1" is of the order of the day of the user entry page
    9 - the P2_BUILDER_CLOSINGS (261 above value) is the page element that you want to use in the comparison

    I need to do a few things with a potentially hidden page element:

    1 - everytime the page loads, I need to check if the page element (P8_ESTIMATE_JUSTIFICATION) is not null, and if it is indeed not null, make displayed.

    2. when the user enters a value in another element of the page (P8_HOMES_PER_YEAR1), call a function to see if the value is greater than 120% of another element on the page (P2_BUILDER_CLOSINGS) and if yes do this question page (P8_ESTIMATE_JUSTIFICATION).

    I have the function created javascript (showHideEstimateJustification) and in the HTML of the page header. Currently, the function is called with a cheque for onChange on the item page entered by the user as described above (P8_HOMES_PER_YEAR1).

    Questions:

    1. I need to force a SHIPMENT once the user enters the value of P8_HOMES_PER_YEAR1 is available in session state and so the function javascript (other ideas welcome!)

    2. I am currently using the x.style.display = 'inline' versus 'none' to hide and show the page element, where x is derived from var x = document.getElementById (P8_ESTIMATE_JUSTIFICATION) y at - there a better way?


    Any help is greatly appreciated.

    -gary (aka Javascript newbie)

    Hello

    Ok.

    An HTML tag is an object - TABLE, TR, DIV, SPAN, INPUT are all objects. Identify us these objects giving them IDs. An object consists of many different properties. Any time we want information on an object we call javascript by saying it the object, we want to know something and the property we want to know. Thus, if var g you, g.name would be "Gary" and so on.

    No matter when you need information about an object, you can point a variable to it by referencing its ID - var g = document.getElementById("GARY"). var g then lets get all the information I need and, in many cases, update information on the object. var gh = g.style.height var g.value = gValue GOLD and so on.

    Sometimes, however, all you really need is the 'value' of this object, so you can just do - var g = document.getElementById("GARY").value

    So, if you need a bit of information, to set a variable to object.property, but if you need more than one, set the variable to the object itself. Setting the variable to the object is something unique, so is generally faster than the reference to each property using document.getElementById("GARY").value inside and so on - as javascript should start at the top of the document, search for the specific object and then find the property.

    The confusing thing, I think that, coming from a programming, is that each variable is defined using "var" instead of an object type explicit

    OK, back to your page...

    Earlier, we have changed the javascript code to use:

    var closings = &P2_BUILDER_CLOSINGS.;
    

    and Apex would replace & P2_BUILDER_CLOSINGS. with a value, for example, 261, so when the page is rendered, the script actually shows:

    var closings = 261;
    

    Thus, it is digital already. If this part is ok.

    The element "homes" but must be converted to a number by the parseInt() function. The fact that you see "NaN" (which is, as you say, a shortened version of 'Not a number'), means that the value it is to see is not numeric. If the first test would be to add an alert message () to display the value of document.getElementById('P8_HOMES_PER_YEAR1').value. It is likely that non-numeric characters are entered? There may be problems with commas or currency symbols

    Andy

  • Hide/show a dynamic field

    Hello

    I'm new to OFA.

    I have a requirement to hide/show a dynamic field based on the operating unit.

    So instead of hard coding UO, I use lookup.

    Now, what I've done, spread the VO and VO query added a new column to validate in relation to research and back 'n' or 'Y '.

    I created a transitional and in VORowImpl attribute. I'm valid against the newly added column VO and assigning the value TRUE or FALSE to the transitional attribute.

    and I'm on SPEL in Customizing the page.

    Now what is happening is when an existing record is asked in the page, the field is hidden/unhinden based on the given condition.

    But when a new record is created, this condition does not work.

    So I guess that the VO don't get initialized when the page is loaded? Is this the reason why the condition is unchecked in VORowImpl?

    My hypothesis is correct?

    How do I get my requirement?

    Pointers would be useful...

    Thank you

    Naren

    Hi AJ,.

    I forgot to update the thread. Reached the requirement.

    Solution,

    Created a transient VO attribute.

    Then in VORowImpl, written the code to set the transient attribute.

    Then using customization, SPELL, set the property to the item.

    It works perfectly.

    Thank you for guiding me to assign to the attribute.

    Kind regards

    Naren

  • "Hide / show" regions – how to keep open after send the page

    Hello

    I have several regions ' hide / show ' in my request... when the user submits the page, it closes all the

    is there a way to keep one open that were opened before the page is sent?

    Thanks in advance

    Long answer: forget the hidden item and simply store the values in a cookie.  Use dynamic action, 1 2 plan to store the values when the page is submitted and the 2nd DA to retrieve the value and developing regions.

    Hide and Show parts APEX sticky

    Dynamic action 1

    Name: Save the open areas

    Event: before the Page is sent

    Condition: - no requirement.

    Real Action:

    Action: Run the JavaScript Code

    Fire on Page load: [disabled]

    Code:

    var lOpenRegions = []
    $(".hide:visible").parent(".hide-show-region").each(function()
      { lOpenRegions.push($(this).attr("id")) });
    SetCookie("HideShowOpenRegions",lOpenRegions.join(","));
    

    Dynamic action 2

    Nom : Open saved regions

    Event: Loading the page

    Condition: - unconditionally.

    Real Action:

    Action: Run the JavaScript Code

    Fire on Page load: [disabled]

    Code:

    if (GetCookie("HideShowOpenRegions")) {
      $.each( GetCookie("HideShowOpenRegions").split(','),
                function(intIndex, objValue) {
                  $("#"+$nvl(objValue,"x")+" .hide:first").show();
                }
      );
    }
    
  • How to hide post text of item in page element

    Hi friends,

    I have a page titled Justification in which under the element text of this article post I give as
    <br><div style="color:blue" font size="1">(240 char max)</font></div>
    Inorder to view a note behind the element.

    But the element of justification page must don't come until after checking the page of another element called reason (which is an option button). So for this I wrote a DA(hide/show) for display of the justification of the point of the page only when the page right element is checked.

    But the problem is that the text of element position within this element of page Justification does not hide with this element (in the DA).


    How can I hide the text of item post in the justification for page element. so I can see this text when the reason page element box is checked as well as the justification for a page element.

    Brgds,
    Mini

    Hey Mini,

    I just write bad :/

    The function is $x_Hide () not $p_Hide ();

    Thnx

  • Dynamic action - show/hide area based on LOV that returns the ID

    Hi people,

    This should be simple, so someone who works with dynamic actions.

    I have a LOV based on query below:
    select OBJECT_ID, KOD 
      from x_data x;
    
    retuns:
       ID          KOD
    ----------------------------
        492961 BMW
        492964 VOLVO
        492960 MERCEDES
        492963 VOLKSWAGEN
        492959 SKODA
    Agenda: P200_KOD is based on LOV that displays KOD and returns the ID.

    On my page, I have also 1 region called TEST_REGION.

    I want to put in place a testament of shich dynamic action SHOW/HIDE a TEST_REGION based on the value selected in the order of the day: P200_KOD (LOV). Region should be shown if displayed (KOD) selected ID value begins with '% V '.
    By other words, if following query returns any folder, then the SHOW, HIDE it on the other:
       select *
        from x_data x
      where x.kod like 'V%'
         and x.object_id = :P200_KOD;
    How can I define a condition of dynamic action fires, for article: P200_KOD?

    Thank you
    Tomas

    Hello

    One way:

    Create an advanced dynamic action.
    Name: Region to hide
    Event: change
    Selection type: item (s)
    Items (s): P200_KOD
    Condition: Expression of JavaScript
    Value:

    $(this.triggeringElement).children("option:selected").html().substring(0,1) !== "V"
    

    Action: hide
    Fire on the Page loading: true
    Hide all items on the page on the same line: No.
    Action of false: show
    Fire on the Page loading: true
    Display all items in the page on the same line: No.
    Selection type: region
    Region: TEST_REGION

    Kind regards
    Jari

    http://dbswh.webhop.NET/dbswh/f?p=blog:Home:0

  • Hide filter interactive report dynamically after the page load

    Hello

    I try to hide the section of interactive report filters (hide/show the area with +/-sign on the top of the report) the loading of the page

    I have the reference to the thread after http://apex-at-work.blogspot.com/2011/02/hide-interactive-report-filter.html posted by Tobias Arnhold...

    According to the expert, all I have to do is post the following code the code JS "page loading" within a dynamic action...


    / * Hide filter IRR after page load * /.
    If ($('#apexir_CONTROLS_IMAGE').attr ("src") == ' / i/minus.gif ') {}
    gReport.toggle_controls ($x ('apexir_CONTROL_PANEL_CONTROL'));
    }

    I did, but apparently it does not work for me...

    I posted a sample on APEX. Oracle.com for review and comment

    Thank you

    Edited by: qwe12654 may 3, 2011 19:15

    Hello

    01. in the report Footer region put this

    
    

    * This will hide your filters, highlight conditions

    02. then Goto 'Report attributes' => 'Search Bar' => for 'Include search bar' select 'no '.
    * This will hide the full search bar (do this only if you want to hide this part)

    * If you get the answer then mark as 'Correct '.

  • Hide/show the area, keep the value between pages?

    Hello

    I use APEX 3.2.1 with Oracle 10 g on Windows XP Pro SP3.

    I have 2 menus (regions) that can be hidden or shown by clicking on an image (as in some IDE). The following javascript code is called on the event 'onClick ':
    function visibilite(region,image) {
         if (region.style.display == "none")
              region.style.display = "" ;
         else
              region.style.display = "none" ;
         if (image.src.indexOf('gauche.png',1) == -1)
              image.src = image.src.replace('droite.png','gauche.png');
         else
              image.src = image.src.replace('gauche.png','droite.png');
    }
    It works perfectly, but when I navigate to another page, the menus are obviously displayed by default...
    So, I just want to keep the value of the previous page to show or hide my menus in the current page.

    I can add the page element in all pages and assign the value using the url, but it is not optimized as I will have a lot of pages (> 100).
    I can use a request element too, but I tried and I can't assign a javascript value, and I don't know if this is a good solution because it will force I call the javascript function, just after that the menu will be displayed, to hide quickly.

    anyone think of another solution?

    Thank you.

    Yann.

    I can add the page element in all pages and assign the value using the url, but it is not optimized as I will have a lot of pages (> 100).

    Create a Page 0 item which will be available on all pages.

    OR

    I can use a request element too, but I tried and I can't assign a javascript value

    Enforcement point values can be set from JavaScript using AJAX and an application process.

  • How to hide/show a dynamic region

    I need to hide/show a region according to the value selected by the user from a selection list. Does anyone have anyidea about how to do it?

    Thank you!

    Create the function to hide show anywhere where you would create javascript. You can put it in a static file, html page, the model of page header that works for you.

    You must call the function of certain events on the selection list. I think that onchange would work. You can set this in the attributes of the element of the selection list element (e.g. onchange = "show_hide ()"). Or you can register the handler through javascript.

    To make it simple for you simply create the function to hide show inside a script tag in the HTML of the page header. It is located on the page at the top left region the most.

    Access to your selection list item, and then look for the "form element HTML attributes. OnChange = "show_hide () of type" in this area. "

    Greg

  • Hide region show how to maintain the status of hide/show on send page

    APEX 4.2.1 using theme 24

    I have several areas on a single page that are defined using the "Hide Show Region" model this model defines the regions to show everything first. If a user chooses to hide a region is there a way to keep this state when the page is submitted? Example region top of page is to hide/show parent to an interactive report, below this area is a relative of region to hide/show for a tabular presentation, if the user chooses to hide the interactive report region and they enter data in the region in a table, when he clicks on save and the page is submitted the interactive report region appears and the tabular form region appears still longer down in the page and the user have to scroll down to access.  I'd rather have the page 'to remember' the State of hide/show that the user has selected for each region and keep this status when the page is sent.

    Someone has an idea how to do this?

    Thanks in advance for a suggestion to work!

    Theresas

    You have almost all the way.

    As you have probably already understood, the problem is that the code requires that regions begin closed and it will 'click' to open.  If you're one of them is already open, you have now two inverse regions.

    I think that it is better to have them both be areas closed, when the cookie should be created (we were a new cookie for that) then "click on" one you want to open and create the cookie with this region in.  From that moment of the code can continue to click on the one that was left pending.

    So, I added more code to the initial opening. I introduced the P2INIT cookie which will be set to YES the first time the page is visited.  Its only purpose is to open the region to report on the first visit.

    After that, the logic can circulate to store regions that can be opened.

    Also, I have completed the static ID of the report to better reference by name.

    Now, I have to say, if you are presenting the same data, but a game is available to edit in a tabular form, something like Page 3 would work?

    When you click on edit the grid it will hide the report and view the form in a table. When you click 'View report' he hide the form tab and view the report.

    I think it's a clean approach and the data are not queried the DB double. It also avoids the flicker of the openness of the region.  Just an idea.

    I use preferences instead of cookies.  The nice thing about the preferences, it's that they are saved in the DB for the user, so if the same user logs on to another computer or a browser preference comes with them.

    Thank you

    -Jorge

  • Can not set a value by the executed dynamic action on the page element "selection list."

    I created an agenda of the page 'list of selection' and I want to when I change a value in another element of the page set only 'screen '.

    I created a dynamic action on the page element "selection list" for this.

    These are the dynamic action attribute:

    When:

    ======

    Event: change

    Selection type: point

    Article: P29_PURCHASE_ORDER

    Condition: No strings attached

    Advanced:

    ========

    Scope of the event: static

    Identification:

    ==========

    Action: Set

    The ' Action Page when the changed value "attribute of the element of 'list of selection' = 'None', and when I run form the dynamic action run and set the value for once and do not update the value according to the change in the article"list of selection. "

    Note: when I change the previous attribute of 'Redirect and set', dynamic action run and properly value, but the value was hidden soon

    I want to value when the value of change of select list according to this change successfully.

    Please, advice me,

    Best regards

    Mustafa Ezzat

    Hello

    you set the value of the 'Page elements to submit' to P29_PURCHASE_ORDER?

    Then, the SQL statement would use the current selected value.

    This is the help text says: "specify a list separated by commas of the elements of the page that will be submitted to the server and therefore available for use in your"SQL statement"," PL/SQL Expression"or"Body of the PL/SQL function".»

    Kind regards

    Erik-jan

Maybe you are looking for

  • How to retrieve the information stored in iCloud?

    I accidentally deleted some notes and would like to know how to get back them to iCloud

  • lack of Bluetooth

    A few days ago, I bought a HP Sleekbook 14-B104AU (C9M37PA). Missing the bluetooth icon in the box wireless so that I can not set on/off bluetooth more. It was working fine until a day ago, but suddenly the icon disappeared when I tried to turn it on

  • iPhone 6 reiniciando apos uso minutos

    Only recently meu iPhone 6 16 g began a present problems. Imported aplicativo não sendo executado, a fica toda borrada tela is qual e reinicia automatically. JA realizei apagar todos os clamp principle e restore using iTunes o no modo DFU. Ainda sim

  • Halo 2 for Windows Vista

    I am running Windows Vista Business and I can't get the Halo 2 for Windows Vista application runs. It can install it fine, but when I try to run the halo2.exe application, it does nothing. Help me please :D

  • Computer TouchSmart HP Envy 17 t 2 weeks without a break stop at or just after the connection

    Hello I really need help because I am pulling all my hair out with frustration. Here are the details: I got a new Notebook HP TouchSmart 17 t for my birthday last week. I'm a developer and a code about 15 hours a day, and my laptop 15 inch 3 years wa