How to close popup with af:commandButton without submitting values?

Hi all,
I'm using JDeveloper 11.1.2.1
My popup has few af:inputText components with value attribute binded to view scope variables.
I set those view scope variables in backing bean before showing popup.
When I change values of input fields and click cancel (af:commandButton, partialSubmit=true, immediate=true), popup is closed.
Then, when I show popup again, values that I changed are visible although I set new values to view scope variables in backing bean before showing popup again.
I noticed that when I close popup using close icon in upper right corner of popup everything works fine.
Also, I tried using dialog cancel button and it also works fine.
Is there a way for closing popup using af:commandButton but without submitting values?
In previous releases of JDeveloper (<= 11.1.1.5) I didn't noticed this problem.
Thanks in advance,
Aleksandar

Alexandar wrote:
Is there a way for closing popup using af:commandButton but without submitting values?If you really want to use your own button without submitting, then some three lines of Javascript will do the trick. See the documentation of af:popup for that. Canceling a popup is a pure client-side operation. No event is sent to the server. No submit. No need to reset anything. That's basically what the built-in cancel button does as well.
Sascha

Similar Messages

  • How to close PopUp (from taskflow region)???

    Can someone, please, explain how to solve this use-case:
    I have PopUp in which I put a region (in which is a small TaskFlow consiting of 2 JSFFs). I want to have Cancel and OK buttons in both JSFFs in TaskFlow. How to close PopUp from within TaskFlow ??? I saw the TaskFlow Return component in ADF TaskFlow diagram components (in palette) but haven't found any help/documentation on it. Or, should I use Return listener on command button used to rise popup (but, still, how to close popup from taskflow?)?
    Any help would be great!
    Thanks in advance,
    Marko

    mimarko,
    Regions/Taskflows are meant to be isolated reusable components. They are not meant to
    have knowledge of their parent or container. That said, code contained with in a region should not attempt to reach out an modify the parent. Regions can fire contextual events that can be handled by a listener declared in the parent pages pageDef. However, attempting to close a popup from a context listener would be bad practice. The easiest fixt is to put the popup in the taskflow for your region. That will create a reusable popup that you can use through out your application.
    --Ric                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   

  • How can I pair with Apple TV without going to set up on Apple TV?

    How can I pair with Apple TV without going to set up on Apple TV?

    Sign up for what? All you need is airplay enabled on ATV, then when iPad is on the same network you double tap home button, swipe (left to right motion) and you will bring up the volume/brightness controls, along with airplay. Tap on airplay (rectangle with triangle in it) and select ATV, toggle ON mirroring.
    The only way to mirror the iPad is wirelessly through ATV or by purchasing the adapter and connecting directly to your TV. Bluetooth via your Blu-Ray player won't help with this.
    http://support.apple.com/kb/TS4085

  • Error after close popup with swfloader

    Hi all, hope some one could help me with this i get this
    error ( Error: Unable to load '' ) each time after i close a popup
    with a swfloader the error popsup when i click on the datagrid
    *****************************main mxml
    private function ShowPano():void
    var SWFLoaderInstance:Panoramica2 =
    Panoramica2(PopUpManager.createPopUp(this,Panoramica2,true));//
    instantiate and show the title window
    PopUpManager.centerPopUp(SWFLoaderInstance);
    SWFLoaderInstance.mainAppPano = this //Reference to the main
    app
    scope
    *******************************this is the mxml Panoramica2
    <?xml version="1.0" encoding="utf-8"?>
    <mx:Canvas xmlns:mx="
    http://www.adobe.com/2006/mxml"
    creationComplete="doInt()"
    cornerRadius="10" width="600" height="450">
    <mx:Script><![CDATA[
    import mx.controls.PopUpMenuButton;
    import mx.managers.PopUpManager;
    import mx.collections.ArrayCollection;
    import mx.controls.Button;
    [Bindable]public var mainAppPano:Object = null;
    //called by the close event raised byclicking the close
    button
    private function closeWindow():void
    PopUpManager.removePopUp(this);
    }//closeWindow
    private function doInt():void
    PopUpManager.centerPopUp(this);
    ]]>
    </mx:Script>
    <mx:TitleWindow layout="absolute" right="10" left="10"
    showCloseButton="true"
    close="closeWindow()" top="10" bottom="10">
    <mx:SWFLoader
    source="{mainAppPano.datagrid.selectedItem.pano..src}"
    scaleContent="false"
    horizontalCenter="0" verticalCenter="0"/>
    </mx:TitleWindow>
    </mx:Canvas>
    ********************************xml structure
    <catalog>
    <libro>
    <name><![CDATA[<b>Biblioteca Central
    </b> ]]></name>
    <desc><![CDATA[Se inauguró el 20 de noviembre
    de 1978 ]]></desc>
    <imagen>FOTOS/est/Biblioteca Central Manuel Bartlett
    Bautista.jpeg</
    imagen>
    <pano nombrePano="Biblioteca Central Bautista">
    <src>FOTOS/Panoramicas/PanoZoom642007.swf</src>
    </pano>
    <ico>BOTONES/gifs/video.gif</ico>
    <video nombreVid="Biblioteca Manuel Bartlet">
    <src>VIDEOS/Biblioteca Manuel Bartlet.flv</src>
    </video>
    <audio/>
    <pie>Biblioteca Central Manuel Bartlett
    Bautista</pie>
    </libro>
    </catalog>

    <script type="text/javascript">
    function saveChanges(){
    doSubmit('SUBMIT');
    var test = $x('P7_FLAG').value;
    if(test == '1')
    window.close();
    window.opener.doSubmit('REFRESH');
    </script>javascript does not wait for the current action to complete and then perform the next line.
    means in your function call
    doSubmit('SUBMIT');is triggered and it carry on's to next line that is
    $x('P7_FLAG').value;this will not be set because you are setting the value of P7_FLAG to 1 in plsql and trying to check in javascript, which will not work.
    what you need to do is amend your js function like below
    <script type="text/javascript">
    function saveChanges(){
    doSubmit('SUBMIT');
    </script>create a page branch to procedure and make it conditional to when P7_FLAG = 1
    and set the branch source to below
    htp.p('window.close();');
    htp.p('window.opener.doSubmit(''REFRESH'');');

  • How can I sync with this library without erasing my data?

    The iPod "Sayira's iPod" is synced with another iTunes library. Do you want to erase this iPod and sync with this iTunes library? An iPod can be synced with only one iTunes library at a time. Erasing and syncing replaces the contents of this iPod with the contents of this iTunes library.
    So, okay, here's my story: My laptop caught a virus, so i sent it to this guy who fixes computers, now that my laptop is fixed, everything is deleted from it. I didn't really mind this too much, but anyway I redownloaded iTunes to my new hardrive and then it said the following (posted above). My question is, how can i sync with this new library without erasing any data from my apps (such as games, photos, videos, music)? I REALLY don't want to lose this data!

    - Transffer iTunes purchases to the computer by:
    iTunes Store: Transferring purchases from your iOS device or iPod to a computer
    - Transfer other music by using a third-party program like one of those discussed here.
    Copy music
    - Connect the iPod to the computer and make a backup by right clicking on the iPod under Devices in iTunes and select Back Up
    - Restore the IPod from that backup
    Note that the backup that iTunes makes does no include symec media like apps and music.

  • Safari 5.1.7 Tab - How to close them with 1 click?

    I have just installed Safari 5.1.7.
    What happened to the X in the tabs to close them?
    I have looked in preferences, can't see any obvious way of restoring the missing "click on the X to close" option.
    I now have to right click & select close from a drop down list. That's nuts!
    I would love a solution to this before I end up reverting to version 5.1.6.

    If only it were that easy Barry.
    I've tried hovering and gave up after 20 seconds.
    I wasn't the first to use Safari after the upgrade to 5.1.7 & I wonder if the other user has some how managed to alter some obscure setting without knowing what she was doing.
    Anyone else have any ideas?

  • How to detect JRE with Javascript and without any help of class file

    Please tell me how to detect JRE with using the Applet file. Is it possible to detect only through Javascript

    It is possible to detect the Sun JRE using only Javascript without any class file.
    However, it is rather complicated due to difficulties with Internet Explorer.
    http://forum.java.sun.com/thread.jspa?threadID=5177843&tstart=15
    http://www.pinlady.net/test/PluginDetect.htm

  • How to close application with IOS 7

    With the new update, I don't know how to close all my app. Could someone please help me :)
    Thanks in advance
    Vicky

    All you have to do is double tap the home button to bring up the multi-tasking view, then swipe up on the screenshot of the app you want to exit.

  • How to Close Popup Window

    Hi All,
    in my main View iam calling a popup window, there i select some values and when i click select button i want to close the popup window.
    Thanks,
    RAju.

    Hi Raju,
    What you can do is while creating the pop window you can take the reference of window manager in some reference attribute of type IF_WD_WINDOW in component controller like.
    wd_comp_controller->gr_window         =
    lr_window_manager->create_window(
                         window_name            = 'Window'
    if_wd_window=>co_msg_display_mode_selected
    *                  close_button           = abap_true
                         button_kind            = if_wd_window=>co_buttons_ok
                         message_type           = if_wd_window=>co_msg_type_none
                         default_button         = if_wd_window=>co_button_ok
    **and now you can call the close method of window at the event you want to close pop up window.
    wd_comp_controller->gr_window->close().
    Regards
    Amol

  • How do you stop with open sites without permission?

    When I'm using mozilla firefox open some sites without my permission. And when I'm not using the browser it opens sites alone too.
    I have passed anti-virus and removed all unneeded extensions him.
    How do I make it stop opening these sites alone?
    PS: I've tried blocking cockies and images, but to no avail. I hope you can help me please.
    thank you!

    The Reset Firefox feature can fix many issues by restoring Firefox to its factory default state while saving your essential information.
    Note: ''This will cause you to lose any Extensions, Open websites, and some Preferences.''
    To Reset Firefox do the following:
    #Go to Firefox > Help > Troubleshooting Information.
    #Click the "Reset Firefox" button.
    #Firefox will close and reset. After Firefox is done, it will show a window with the information that is imported. Click Finish.
    #Firefox will open with all factory defaults applied.
    Further information can be found in the [[Reset Firefox – easily fix most problems]] article.
    Did this fix your problems? Please report back to us!

  • Open and Close Popup With Javascript

    Using Apex 3.2
    I have probably done this loads of times in my old job, but do not have access to the code and today I just can't get it to work properly.
    I have opened a pop up window with javascript
    Now I need to close it and refresh the calling page, but only if it passes the validation on the popup.
    I have a hidden item on my pop up called P7_FLAG.
    I have a page process after validation that sets P7_FLAG to (only set to 1, if passes validation).
    I also have a SUBMIT button.
    So once I click my SUBMIT button the page should look at the validations, if ok, set P7_FLAG to 1, then close the popup and refresh the calling page.
    My current javascript look like this
    <script type="text/javascript">
    function saveChanges(){
    doSubmit('SUBMIT');
    var test = $x('P7_FLAG').value;
    if(test == '1')
    window.close();
    window.opener.doSubmit('REFRESH');
    </script>On my button
    javascript:saveChanges();The problem is that I need to click the SUBMIT button twice.
    First time it sets P7_FLAG
    Second time it closes page and refreshes.
    I have probably made some basic error, but today I cannot see it.
    Cheers
    Gus
    Edited by: Gus C on May 10, 2012 12:48 AM

    <script type="text/javascript">
    function saveChanges(){
    doSubmit('SUBMIT');
    var test = $x('P7_FLAG').value;
    if(test == '1')
    window.close();
    window.opener.doSubmit('REFRESH');
    </script>javascript does not wait for the current action to complete and then perform the next line.
    means in your function call
    doSubmit('SUBMIT');is triggered and it carry on's to next line that is
    $x('P7_FLAG').value;this will not be set because you are setting the value of P7_FLAG to 1 in plsql and trying to check in javascript, which will not work.
    what you need to do is amend your js function like below
    <script type="text/javascript">
    function saveChanges(){
    doSubmit('SUBMIT');
    </script>create a page branch to procedure and make it conditional to when P7_FLAG = 1
    and set the branch source to below
    htp.p('window.close();');
    htp.p('window.opener.doSubmit(''REFRESH'');');

  • Flex mobile - close popUp with back hardware key - bug?

    Hi everyone,
    i am having a problem with a popUp in my firstView aka HomeView. I used a similar logic as provided by the DashBoardMobile reference example: (http://www.adobe.com/products/flex/examples/)
    when i open the PopUP i add a EventListener with the HandlerFunction to close the popUp if the device back-key is pressed:
    systemManager.stage.addEventListener(KeyboardEvent.KEY_UP, deviceKeyUpHandler, false, 1000, true);
    protected function deviceKeyUpHandler(event:KeyboardEvent):void
                    var key:uint = event.keyCode;
                    if (key == Keyboard.BACK)
                        event.stopImmediatePropagation();
                        event.stopPropagation();
                        closePopUp();
    So far this had worked fine (if a popUp is open its get closed, if no popUp is open the previous View is poped)
    Now i made a popUp for the firstView of my app, and there this doesnt works, if i press the back-kay the application is closed wether the popUp is open or not...

    You might want to try listening for the backKeyPressed event on the View instead: http://polygeek.com/4225_air-mobile_go-your-own-way-overriding-the-back-key-press-in-air-m obile-apps
    In that handler if your popup is open you'll want to preventDefault() on the event and call your close logic.

  • Close popup with branch

    I have created a page with a "New party" button that opens a popup. It clears that cache for the popup and works fine.
    The new party can be entered and "create"d. The page branches to itself and the create button is not displayed. The new party data is saved in the table.
    The popup page has a computatoin to put the party_id into the calling page item. The Cancel button is a URL target: javascript:window.close();. This closes the window.
    Two questions;
    I want the branch to be a URL target that closes the page but I can't get it to work. The URL calls this in the Page HTML Header:
    <script language="JavaScript1.1" type="text/javascript">
    function passBack(){
    window.close();
    window.opener.location.reload(true);
    I made the only branch a URL and entered this as the url: -- javascript:passback() -- It never executed the function.
    I then tried -- javascript: window.close(); -- and the window did not close. This is the same code the Cancel button uses.
    What am I missing?
    Second question; I clicked the Cancel butoong, the window closed and on the calling page I looked at the session variables and the party_id was flagged as R but I did not see the value? Did it not write the session variable? Is there any way for me to check?
    Tia,
    Sam

    Sam,
    Why are you trying to take the user away from the current page? This can over complicate things. Have you considered a wizard approach where they could select "Create New" which would allow them to create the new entity?
    What I've found to work best is to provide a link to another action and bring the user back. For example, lets say I have a two step process: Create User and Assign User to Projects. In the wizard to Assign User to Projects I'll provide a link that says Create User. The link takes the user to the Create User wizard while setting the value of an item that the Create User wizard will later reference to bring the user back to the same spot in the Assign Users wizard.
    Regards,
    Dan
    http://danielmcghan.us
    http://sourceforge.net/projects/tapigen

  • How to have icons with a WM (without installing a whole DE)

    Hi!
    I was wondering if it was possible to have desktop icons with TWM/FluxBox/IceWM alone, without installing a desktop environment. As far as I know, file managers do this in DEs but then simply installing a file manager while running a WM doesn't put icons on the screen...
    Thank you in advance!

    Thank you guys! I actually searched not only through the wiki but tried to google it too. Now I feel sorry to have opened a thread that can be solved with a link from the wiki. Maybe I should have looked better... Nevertheless, thank you for the information.
    I was trying to make a lightweight system so looks like nautilus isn't for me (as Trilby said I will need to install gnome too, which is too heavy for my goals). I will however try to make it show the files that are in /user/Desktop/ for the sake of it... I don't like leaving things halfway done! Then I will maybe move on to rox and pcmanfm but one thing is for sure - I LOVE icons and it doesn't matter how lightweight a system is, for me, it is a must to have icons
    And about Tdy's responce:
    I haven't thought about these icons you said. I actually wanted that everything in /user/Desktop be showed on the desktop but I sure think that those you suggested would come in handy too. I will think about them after I have finished the main task, that is - the /user/Desktop/ thing
    Thank you again!

  • How to close S/A bridge immediatly without calling any asyn comm?

    Hi,
    how can i close an S/A bridge immediatly (so i have only a sync/receive(start S/A) and immediatly a sync/send(close S/A bridge)?
    thanks,
    Peter Ha

    Hi Peter,
    When one opens a Sync-Async bridge..one has to give syncronous interface and the message coming in(the request message of the sync interface)....and on closing the bridge, one has to give the step which open the bridge and the message to be sent back(this has to be the response message in the sync interface)...
    In your situation, if the receive step(open bridge) is followed by the send step(close bridge)...how are you making/getting the response message?
    Supposing, your sync interface has the same message type as request and response....then you can close the bridge with the same message that came in (this is just a case of trying to have the open and close step right next to each other)
    Thanks & Regards,
    Renjith.

Maybe you are looking for

  • How to control the video playback function on ipad?

    Hi there, I am creating a project containing video content that will be delivered on an ipad. I would like my video to behave like many other videos do on ipad publications: 1. I want the poster frame of the video to appear small on the page before i

  • EIC Web Client Timeout value

    Hello, I am trying to help our EIC users with a request. They say that the web client times out and closes on them after about 5 minutes of inactivity. They would like to increase the timeout value. Unfortunately the person who implemented this is no

  • TS2634 When I open iTunes using PC, the device does not show up anywhere

    The device does not show up anywhere.  This is happening for iPhone and iPad.  Thoughts?

  • Best codec for data discs?

    I want to clear a large project off my drive by burning it onto data discs. What's the best codec to use for later FCP editing? On a slightly different topic, is there a best "universal" codec that can be edited in other popular NLE systems, e.g. Avi

  • Flash plays before html page is completely loaded

    A flash intro for a website's homepage starts to play before the html page elements are completely loaded and visible. The html page is not complicated so it would seem the flash is even slowing down the loading of the html and it looks bad, but not