Newbie:  Blocking Actions in JavaScript

Hello,
I want to do something that should be very simple.  I want too prevent a form from being submitted if a dropdown has a particular value and a signature is present in a signature block.  I would be happy to block the signature from taking place as well, as that would accomplish the same goal.  All I want to do is post a message to the user when the submit button is pressed and prevent the action from occuring.  Any help is appreciated!
-Alex

I have been able to get this to work using both access restrictions and presence changes on change events.  However, I cannot get it to do this on initialization.
Here is my initialization code:
if (xfa.event.newText == "Not Reviewed"){pmReview.presence = "invisible";}
else {pmReview.presence = "visible";}
Any help is appreciated.
-Alex

Similar Messages

  • What is the best way to call a pageflow action from JavaScript?

    What is the best way to call a pageflow action from JavaScript?
    Thanks,
    John

    John,
    How would I do this from a grid??? Unfortunately there are no JavaScript attributes
    on any of the grid tags that I can see.
    Thanks,
    John
    "John H" <[email protected]> wrote:
    >
    Thanks John!
    "John Rohrlich" <[email protected]> wrote:
    John,
    If you want to put up a confirm dialog before calling an action from
    an
    anchor it is done as follows.
    Here is an example from code of mine that deletes a customer order,if
    the
    user confirms the delete. I pass the order id as a parameter.
    - john
    Here is the JavaScript -
    function confirmDelete() {
    if(confirm('Continue with order delete?'))
    return true;
    else
    return false;
    Here is a sample anchor tag -
    <netui:anchor action="requestToDeleteOrder" onClick="return
    confirmDelete(); return false;">
    Delete
    <netui:parameter name="orderId" value="{container.item.orderId}"/>
    </netui:anchor>
    "John H" <[email protected]> wrote in message
    news:402138f5$[email protected]..
    Thanks for the replies. I figured it was going to require buildingmy own
    url
    to call the action. I had hoped there was an easier way to do it.Rich,
    the
    reason I want to do this is because I want to call the JavaScript
    function
    confirm()
    when a user clicks on a link (in a repeater/grid) to drop a record,I only
    want
    to call the drop action if the user confirms the drop. Maybe thereis a
    better
    way to do what I am trying to do??? I really appreciate any help
    you
    guys
    can
    give me on this, I am pretty new to this sort of stuff.
    Thanks,
    John
    "Rich Kucera" <[email protected]> wrote:
    "John H" <[email protected]> wrote:
    What is the best way to call a pageflow action from JavaScript?
    Thanks,
    JohnTry figuring out the URL to the pageflow action, create a hidden
    form
    in the
    page, then use JS to submit the form. Why would you want to though,
    isn't
    the server going to want to send you to the next page?

  • Handling unit  was not blocked - action cancelled VL02N

    Dear All,
    While pack VL02N data upload by bapi HU_PACKING_AND_UNPACKING its showing error
    Handling unit  was not blocked - action cancelled
    Mohamed

    Refer OSS Note 370195 , 331715

  • Can I run an action via javascript?

    I would like to know if it is possible to configure acrobat to launch a custom action created from the action wizard on startup. I'd like to automate the process so that a user would not have to manually start the action, but simply start the program. Thanks.

    Thank you for your replies. I am new to Acrobat so I appreciate your help and patience.  In this case every user does have a license. We have used Acrobat for other purposes in the past. We were hoping to be able to use acrobat for this as well. However it sounds like running an action from javascript or some other source would be difficult. Does anyone know if it can be done and if so how to do it? If not I guess I'll just have to look into other options. Once again thank you all for your input.

  • Call actions through javascript

    Hi Everyone,
    Currently i'm doing automations for Adobe Illustrator CS4. I have created some actions due to the limitations of scripting in Illustrator. I need to call this actions through javascript.
    But in applescript i can able to call the actions by using the do script method.
    Can anyone help me in this regard.
    Thanks in advance
    Thiyagu

    May this can help you. VBS version:
    Set appRef = CreateObject("Illustrator.Application")
    'action name "Convert to grayscale", action set"action1"'
    appRef.DoScript "Convert to grayscale", "action1"
    'sleep 2 sec, waiting for the action complete, this is needed if you want to do something else'
    WScript.sleep 2000
    ' then do something else here

  • Error 'Handling unit was not blocked - action cancelled' for Packing

    Hi Friends
    I am trying to execute Functional Module  HU_PACKING_AND_UNPACKING  to Pack Sales Order Line Items in to HU.
    But System is throwing unusual error Handling unit was not blocked - action cancelled
    The Other SAP SDN thread advised to implement  OSS Note 370195 , 331715.
    The Input Code given in the Note  370195 SAP Developer can not find in our system.
    SAP Note 331715 already implemented in our system.
    Please help to resolve the issue for Packing Sales Order Line Items in to HU.
    Thanks
    SR

    Refer OSS Note 370195 , 331715

  • Call struts action from javascript?

    Hi all
    I'm having problem already discussed here quite a lot, but I have idea to solve it different way. And need to know is it possible or I'm doing mission impossible here :(
    I have JSP with 2 drop down lilsts, where the second is populated according to selected value from first - that's basically my problem.
    Is it possible to somehow only call my struts action which will return all needed values using javascript and onchange event handler?
    I dont have any experience with javascript, and I'm trying to avoid it as much as possible at the moment.
    Thanks in advance

    well as far your requirement is concern if at all you are planning to implement AJAX try to use the below link which might be of some help...
    http://www.it-eye.nl/weblog/2005/12/13/ajax-in-struts-implementing-dependend-select-boxes/
    However,I somehow feel there are few loopholes in the author's approach...
    i advice to use XmlHttpRequest.reponseXML property there.
    However, i've mentioned a sample code snippet for you reference.
    XML Response Pattern :
    ======================
    <? xml version="1.1" ?>
    <dropdown>
    <option>
    <val>CUSTOMIZED_VALUE</val>
    <text>CUSTOMIZED_VALUE</text>
    </option>
    </dropdown>Sample.jsp:
    ===========
    <%@page language="java" %>
    <html>
        <head>
            <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
            <title>Automatic Drop-Down Updation</title>
         <script language="javascript">
          // Global Variable for XmlHttp Request Object  
          var xmlhttp
          // Timer Variables
          var c = 0
          var t
           /* A function which calls a servlet  named AjaxServlet to get XmlData using XmlHttpObject */    
            function refreshCombo(txt){
                xmlhttp = null
                // code for initializing XmlHttpRequest Object On Browsers like  Mozilla, etc.
                if (window.XMLHttpRequest){
                     xmlhttp = new XMLHttpRequest()
                // code for initializing XmlHttpRequest Object On Browsers like IE
               else if (window.ActiveXObject) {
                   xmlhttp = new ActiveXObject("Microsoft.XMLHTTP")
               if (xmlhttp != null){
                  // Setting the Action url to get XmlData
                   url = "dropdown.do?count="+txt;
                   // Course of Action That Should be Made if their is a change in XmlHttpRequest Object ReadyState NOTE : it is 4 when it has got request from CGI
                   xmlhttp.onreadystatechange = getResponseAction;
                   // Open the Request by passing Type of Request & CGI URL
                   xmlhttp.open("GET",url,true);
                   // Sending URL Encoded Data
                   xmlhttp.send(null);
               else{
                 // Only Broswers like IE 5.0,Mozilla & all other browser which support XML data Supports AJAX Technology
                 // In the Below case it looks as if the browser is not compatiable
                  alert("Your browser does not support XMLHTTP.")
          /* Used for verifing right ReadyState & Status of XmlHttpRequest Object returns true if it is verified */
          function verifyReadyState(obj){
             // As Said above if XmlHttp.ReadyState == 4 then the Page Has got Response from WebServer
              if(obj.readyState == 4){
               // Similarly if XmlHttp.status == 200 it means that we have got a Valid response from the WebServer
                if(obj.status == 200){               
                    return true
                 else{
                    alert("Problem retrieving XML data")
          /* Action that has to take place after getting reponse */
          function getResponseAction(){
              // Verifying State & Status
              if(verifyReadyState(xmlhttp) == true){
                  // Building a DOM parser from Response Object
                  var response = xmlhttp.responseXML.documentElement
                  // Deleting all the Present Elements in the Drop-Down Box
                  drRemove()      
                  // Checking for the Root Node Tag
                  var x = response.getElementsByTagName("option")
                  var val
                  var tex
                  var optn
                  for(var i = 0;i < x.length; i++){
                     optn = document.createElement("OPTION")
                     var er
                     // Checking for the tag which holds the value of the Drop-Down combo element
                     val = x.getElementsByTagName("val")
    try{
    // Assigning the value to a Drop-Down Set Element
    optn.value = val[0].firstChild.data
    } catch(er){
    // Checking for the tag which holds the Text of the Drop-Down combo element
    tex = x[i].getElementsByTagName("text")
    try{
    // Assigning the Text to a Drop-Down Set Element
    optn.text = tex[0].firstChild.data
    } catch(er){
    // Adding the Set Element to the Drop-Down
    document.SampleForm.SampleCombo.options.add(optn)
    /* Function removes all the elements in the Drop-Down */
    function drRemove(){
    var x = document.SampleForm.SampleCombo
    for(var i = document.SampleForm.SampleCombo.length - 1 ; i >= 0 ; i--){                     
    x.remove(i)
    </script>
    </head>
    <body onload="syncCount()">
    <pre> <h1>Refresh Drop-Down <div id='txt'> </div> </h1></pre>
    <form name="SampleForm">
    <!-- Drop Down which has country list -->
    <select name="x" onchange="refreshCombo(this.value)">
                   <option value="1">United States</option>
                   <option value="2">United Kingdom</option>
                   <option value="3">United Arab Emriates</option>
    </select>
    <!-- Drop Down which is dependent on Country Drop down get list of states -->
    <select name="SampleCombo">
    <option value="-1">Pick One</option>
    </select>
    </form>
    </body>
    </html>
    struts-config.xml:
    ==================
    <action-mappings>
    <action path="/dropdown" type="com.controlleraction.AjaxActionClass">
    <forward name="error" path="/error.jsp"/>
    </action>
    </action-mappings>AjaxActionClass.java:
    =====================
    package com.controlleraction;
    import javax.servlet.http.HttpServletRequest;
    import javax.servlet.http.HttpServletResponse;
    import javax.servlet.http.HttpSession;
    import org.apache.struts.action.ActionErrors;
    import org.apache.struts.action.ActionForm;
    import org.apache.struts.action.ActionForward;
    import org.apache.struts.action.ActionMapping;
    public class AjaxActionClass extends DispatchAction {
      public ActionForward execute( ActionMapping mapping,ActionForm form,HttpServletRequest request,HttpServletResponse response) throws Exception {
        String req = new String("");
        try{
           req = request.getParameter("count");
        } catch(Exception exp){
       if(!req.equals("")){
           response.setContentType("text/xml");        
           response.setHeader("Pragma","no-cache");
           response.setHeader("Cache-Control","no-cache,post-check=0,pre-check=0");
           PrintWriter out = response.getWriter();
           /*a sample bean where we trying to call a service from Model*/
           com.Biz.XmlBean xml = new XmlBean();
           String buffer = xml.getXmlData(req);
           if(xml.close() == true && buffer.equals("") == false)
             out.write(buffer);     
           return(null);
      } else {
         return new ActionForward("error");
    }XmlBean.java:
    =============
    * XmlBean.java
    import java.sql.*;
    import java.util.*;
    import java.io.*;
    * @author RaHuL
    public class XmlBean {
        private Connection con = null;
        private PreparedStatement pstmt = null;
        private ResultSet rs = null;
        // Setting CLASSURL path to TYPE I Driver
        private String CLASSURL = "sun.jdbc.odbc.JdbcOdbcDriver";
        /* Specifing CONNECTION PATH to a DSN named TestDsn
         * Please Make Sure you create a DSN Named TestDsn to your database which holds EMP table
        private String CONNECTIONURL = "jdbc:odbc:TestDsn";
        boolean IS_ESTABLISHED = false;
        /** Creates a new instance of XmlBean and also establishes DB Connections */
        public XmlBean() {
            try{
                Class.forName(CLASSURL);
                con = DriverManager.getConnection(CONNECTIONURL,"admin","");
                IS_ESTABLISHED = true;
            } catch(SQLException sqe){
                sqe.printStackTrace();
            } catch(Exception exp){
                exp.printStackTrace();
        /* Generates XmlData For the Business Logic Specified */
        public String getXmlData(String req){
            String XmlBuffer = new String("");
            if(IS_ESTABLISHED == true){
                try{
                    pstmt = con.prepareStatement("SELECT stateid,statename FROM STATE_TABLE where countryid = ?");
                    pstmt.setString(1,req);
                    rs = pstmt.executeQuery();
                    if(rs != null){
                        XmlBuffer = XmlBuffer + "<?xml version=\"1.0\" encoding=\"ISO-8859-1\" ?>";
                        XmlBuffer = XmlBuffer + "<!--  Edited by Rahul Sharma -->";
                        // Root Node
                        XmlBuffer = XmlBuffer + "<dropdown>";
                        while(rs.next()){
                            String value = rs.getString(1);
                            String text = rs.getString(2);
                            // Sub-root Node
                            XmlBuffer = XmlBuffer + "<option>";
                            // node which holds value of drop-down combo
                            XmlBuffer = XmlBuffer + "<val>"+value+"</val>";
                            // node which holds text for drop-down combo
                            XmlBuffer = XmlBuffer + "<text>"+text+"</text>";
                            XmlBuffer = XmlBuffer + "</option>";
                        XmlBuffer = XmlBuffer + "</dropdown>";
                }catch(SQLException sqe){
                    sqe.printStackTrace();
                } catch(Exception exp){
                    exp.printStackTrace();
            return(XmlBuffer);
        /* Closes the DB Connection Conmpletely */
        public  boolean close(){
            if(IS_ESTABLISHED == true){
                try{
                    pstmt.close();
                    con.close();
                    return(true);
                } catch(SQLException sqe){
                    sqe.printStackTrace();
                } catch(Exception exp){
                    exp.printStackTrace();
            return(false);
    NOTE: I understand i'm not completely coded things as per proper coding standards.please execuse me for that as this example was just given to enable user to learn how XmlHttpRquest,reponseXML
    can be used for better purposes instead of devising manual parsing.
    where i've used XmlHttpResponse pattern to be in XML. you may make use of other practices like JSON & so on depending on your requirement..
    and and if you are more instrested in integrating Struts with AJAX using few frameworks & customized tag based support please go though the below link.
    http://struts.sourceforge.net/ajaxtags/index.html
    Hope that might help :)
    REGARDS,
    RaHuL

  • Queue Block : Action OPEN_PSA_DATAPACKAGE/2 IS NOT SUPPORTED

    I am getting EDI data from XI system to my BI. These days, I am seeing many entires getting stuck in SMQ2. On checking, the first line always has SYSFAIL error. and the statusText shows as Action OPEN_PSA_DATAPACKAGE/2 is not supported in RED color. Some entries are coming successfully to PSA, some records are getting blocked in SMQ2. The IPAK is a real time one, whenever a file is pushed through XI, every minute, it transfers to my BW PSA of an DSO.
    I don't understand what this error mean? Function Module : SXMS_ASYNC_EXEC
    Can anyone explain to me, why these days, this error could occur and what's that meaning ? and the probable reason ?
    Thanks
    Venkat

    Hi Venkat,
    Others customers have resolved the same problem by applying the correction from the SAP note 1489988,
    I know the note does not describe the symptom you have but can you apply the correction from the note if it is valid for
    your support package level and please let us know the results.
    Best Regards,
    Des

  • Adding page actions by javascript

    Hi,
    I know that acrobat holds the option to add "open/close page event", it can be done manually, like in this guide: http://acrobatusers.com/tutorials/print/entering-page-actions
    but i want something else, i want to know if there is a JavaScript command that adds a script to a page event, something like:
    this.addScipt(page=2,
                        event=onClose,
                        "app.alert("Page 2 was closed")"
    Thanks.

    Here's a link to the online Acrobat JavaScript documentation: http://help.adobe.com/livedocs/acrobat_sdk/11/Acrobat11_HTMLHelp/wwhelp/wwhimpl/js/html/ww help.htm?href=JavaScript_Secti…

  • How to call a action in javascript

    hi..
    am a learner..
    can anyone guide me how to call a action in Illustrator CS2 using javascript
    thanks in advance,
    Jasy

    Yep!
    Maybe they prefer Apple. Maybe most of their buyers comes from that side.  Maybe they dont know how to script.
    Java would have been to hard for most of us. Javascript is everywhere on the web ... pages.
    After so many years, they did not put the effort and money . This scripting idea is still for ' amateur' and to compensate for I dont know what.

  • How to use call a binding action using Javascript ?

    Hi adf people,
    JDev : 11.1.1.4.0
    How to submit the binding action using the Javascript ?

    what do u mean by submitting the binding action..???
    for javascript you can either use
    af:clientlistener to call javascript
    af:serverlistener to call from javascript to managed bean
    http://download.oracle.com/docs/cd/E12839_01/apirefs.1111/e12419/tagdoc/af_clientListener.html
    http://download.oracle.com/docs/cd/E15523_01/apirefs.1111/e12419/tagdoc/af_serverListener.html
    please tell us if you need any more information.. or explain your question properly..

  • Form "action" behavior / javascript issue

    I’ve got an HTML page created in Dreamweaver 8.0.2 that
    is designed to put a certain size t-shirt into a Shopping Cart
    (cart.php) via a form – where the user selects the shirt size
    from a List/Menu, and then hits an “add to cart” image
    to fire the form and send its parameters to the cart. Here is a URL
    to a bare-bones page that demonstrates the problem (with a debug
    popup that echos the product name):
    http://www.missioninland.com/problem_demo2.html
    In IE6 and IE7, everything works fine IF AND ONLY IF the user
    actually changes the value of the List/Menu from the default =
    Large to anything else, (or even back to Large after first changing
    it to something else) before hitting “add to cart”. If
    instead the user doesn’t touch the List/Menu (and thus
    accepts the default = Large), then when the user hits the
    “add to cart” – then it never adds the product to
    the cart … as though the javascript portion of the code is
    not running (except that I KNOW it is because I have an
    “alert” debug popup that passes the me value of the
    product).
    In Firefox 2.0.0.15 and Safari 3.1.2, whether the user
    changes the value of the shirt size List/Menu selector or not - it
    never places the item correctly in the cart ... always shows an
    empty cart. The debug popups (which correctly pop up in IE6 and
    IE7) do not appear – and yes, I do have pop-ups enabled in
    both Firefox and Safari. It appears that the javascript code is not
    running – and I’m not sure why.
    The relevant portions of the code are shown beneath my
    signature. Any suggestions? Your help is GREATLY appreciated!
    Greg
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0
    Transitional//EN" "
    http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html xmlns="
    http://www.w3.org/1999/xhtml">
    <head>
    <script language="JavaScript" type="text/javascript">
    function get_selected_productname1()
    var x = document.form1.finalsize.selectedIndex;
    var selected_size =
    document.form1.finalsize.options[x].value;
    var finalproduct = "SEU-" + selected_size;
    document.form1.id.value = finalproduct;
    // this popup tells this routine is being called correctly,
    and is giving me the correct product name, but it only shows itself
    in IE6 and IE7, not in Firefox or Safari (even with popups enabled)
    alert("Final Product = " + finalproduct);
    return finalproduct;
    </script>
    </head>
    <body>
    <form id="form1" name="SE-U" method="post" action="
    http://missioninland.com/cart.php">
    <label>
    <div align="center"><span
    class="style10">Size</span><br />
    <select name="finalsize"
    onChange="get_selected_productname1()" >
    <option value="S">Small</option>
    <option value="M">Medium</option>
    <option value="L"
    selected="selected">Large</option>
    <option value="XL">Extra Large</option>
    </select>
    </div>
    </label>
    <script language="JavaScript" type="text/javascript">
    // ensures this routine gets called at least once, in case
    user doesn't change value of Shirt Size selector from default =
    Large
    var y = get_selected_productname1();
    // uncomment line below for debug - call
    get_selected_productname1 to echo return value to me
    // alert("Final Product = " + get_selected_productname1());
    </script>
    </body>
    </html>

    Here is a much more simplified demo and explanation of what
    Im trying to do and also what else I learned myself last night.
    The ultimate goal is for the user to use the List/Menu to
    pick a size of a t-shirt that will be displayed via a photo above
    the List Menu. The javascript code takes the name of the shirt
    (such as SEU-) and appends a size character to the end of it
    … so that the possible results are SEU-S (for small), SEU-M
    for medium, SEU-L, and SEU-XL.
    You can tell that it works fine if and only if the page you
    are directed to after hitting “add to cart” tells you
    that what you just selected has been added to the cart. It is not
    working fine if it tells you “Sorry – your shopping
    cart is empty”.
    I stripped pretty much everything out of yesterday’s
    code last night, and placed at the new URL below what I have left
    that demonstrates the problem:
    http://www.missioninland.com/simple_demo.html
    In IE6 and IE7, everything works fine no problems (that I
    know of anyway). The debug popups in the javascript function always
    pop-up, and the correct current value of the List/Menu is echoed to
    me. Hitting the “add to cart” button always causes the
    correct shirt descriptor (SEU-S, SEU-M, SEU-L, or SEU-XL) to be
    echoed, and passed successfully into the shopping cart.
    In Firefox 2.0.0.15 and Safari 3.1.2, it does not work at
    all and I’m stumped! [You can see in the test cases below
    how the problem surfaces.]
    There are just two test cases to know that this works:
    Test Case 1 Accepting List/Menu default = Large size shirt
    0) Clear your browser cache; make sure pop-ups are enabled in
    your browser
    1) Call up the page
    http://www.missioninland.com/simple_demo.html
    2) You should immediately see (and do see in IE6 and IE7) the
    first (forced) call to the get_selected_productname1() function
    cause a pop-up to occur with the default shirt size
    “SEU-L” to be displayed to you. Hit “Okay”
    on the pop-up to continue.
    3) Do not touch the List/Menu (which means you accept the
    default size = Large), and only hit the “add to cart”
    button.
    4) a) In IE6 and IE7, what you see next is that the Large
    Shirt (SEU-L) is correctly added to the shopping cart – and
    you are redirected to the shopping cart page that shows it actually
    added. This means success.
    4) b) In Firefox and Safari, something goes wrong (see
    Firebug results below). You never see the pop-up from 2) above, and
    when you hit the “add to cart” button it does not
    successfully pass the form parameters to the cart … which you
    know because the cart says “Sorry Your shopping cart is
    empty”.
    Test Case 2 Changing List/Menu to a different size shirt
    5) Clear your browser cache; make sure pop-ups are enabled in
    your browser
    6) Call up the page
    http://www.missioninland.com/simple_demo.html
    7) You should immediately see (and do see in IE6 and IE7) the
    first (forced) call to the get_selected_productname1() function
    cause a pop-up to occur with the default shirt size
    “SEU-L” to be displayed to you. Hit “Okay”
    on the pop-up to continue.
    8) This time change the value of the List/Menu to something
    like “Medium”. You immediately notice (in IE6 and IE7)
    that the pop-up box echoes the new shirt name (SEU-M) … hit
    okay on the pop-up, then hit the “add to cart” button.
    9) a) In IE6 and IE7, what you see next is that the selected
    shirt (Medium in this case) is correctly added to the shopping cart
    – and you are redirected to the shopping cart page that shows
    it actually added. This means success.
    9) b) In Firefox and Safari, again something goes wrong (see
    Firebug results below). You never see either of the pop-ups, and
    when you hit the “add to cart” button – it does
    not successfully pass the form parameters to the cart … which
    you know because the cart says “Sorry – Your shopping
    cart is empty”.
    Debug Results from Firebug
    So the problem is that everything works fine in IE6 and IE7,
    but does not work at all in Firefox and Safari. I installed Firebug
    into Firefox, and the error it gives me is that
    Document.form1 has no properties
    And it points me to this line of code on line 9.
    var x = document.form1.finalsize.selectedIndex;
    I’ve been staring at this for a while, and I cannot
    figure out how to fix this. If anyone has any ideas, I would be
    exceptionally grateful – as I’m completely stumped.
    Thanks in advance!
    Greg

  • How to block action events?

    Hi,
    how can i block an event call from GUI?
    Imagine i have a button on a page.
    The click on this button call an action listener "buttonClicked".
    I want to call this action listener only in the first click.
    Then, while this method do something, the next clicks on this button do not call the action listener.
    So, after the method ends his execution, i enable the button clicks again.
    Is there any way to do that?
    Thanks.

    I don't know if this is the best solution, but what I did was to pass the components as arguments in the action listener classes. Every time you invoke an action listener for component A that needs to influence component B, pass component B as an argument to a custom setComponentB(componentB) method in B's action listener.
    Here's an example of my code that deals with this. The code implements a database search that displays the results as a list in a scrollable window.
    class MainGUI
    public static void main (String [] args)
    JButton searchButton = new JButton();
    JList resultList = new JList();
    JScrollPane sp = new JScrollPane(resultList);
    SearchButtonListener sbl = new SearchButtonListener();
    sbl.setTarget(resultList);
    searchButton.addActionListener(sbl);
    class SearchButtonListener implements ActionListener
    private JList target;
    void setTarget(JList target)
    this.target = target;
    public void actionPerformed(ActionEvent e)
    // perform database search and store results in Vector resultVector
    target.setListData(resultVector);
    Hope this helps.

  • Jump to Block/Action at Runtime

    Hi all,
    in our business case we need a possibilty, that we are able to jump from one action to another, and that scenario at runtime. Also it should be accessible only for a reduced user circle.
    Is that possible to implement in GP?

    Possible, the case is not clear for me.
    You can attach info callable objects to any action of your parallel block, put according "Process Activities" control item to your process.
    When you are going to instantiate this process you can delegate users to process action roles as you like, and actions will be accessible only for whose users who are assigned to them. The same is for callable object info, users which are not assigned to some action will not see assigned callable object info for this action.
    Also process administartor can review all the activities with assigned callable object infos.
    Best regards,
    Aliaskei

  • Delete button action and javascript

    Hi! In old JDeveloper 10g I can put to my delete button JavaScript to open confirm window on button click - if(confirm(\'You are about to delete the selected record.\' )) {return true;} else {return false;}"
    What can I do in JDeveloper 11g and how to implement this functionality?
    Best regards, Debuger!

    Timo! When I do like You said then I have error: javax.servlet.ServletException: java.lang.NullPointerException
    I created popup and droped ther my delete button from my form. Then in form I created button that shows popup! I removed delete button disabled property so I can press it. But when I run my app. and click on delete button in popup then the following error occours:
    javax.servlet.ServletException: java.lang.NullPointerException
         at javax.faces.webapp.FacesServlet.service(FacesServlet.java:277)
         at weblogic.servlet.internal.StubSecurityHelper$ServletServiceAction.run(StubSecurityHelper.java:227)
         at weblogic.servlet.internal.StubSecurityHelper.invokeServlet(StubSecurityHelper.java:125)
         at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:292)
         at weblogic.servlet.internal.TailFilter.doFilter(TailFilter.java:26)
         at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
         at oracle.adf.model.servlet.ADFBindingFilter.doFilter(ADFBindingFilter.java:191)
         at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
         at oracle.adfinternal.view.faces.webapp.rich.RegistrationFilter.doFilter(RegistrationFilter.java:97)
         at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl$FilterListChain.doFilter(TrinidadFilterImpl.java:420)
         at oracle.adfinternal.view.faces.activedata.AdsFilter.doFilter(AdsFilter.java:60)
         at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl$FilterListChain.doFilter(TrinidadFilterImpl.java:420)
         at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl._doFilterImpl(TrinidadFilterImpl.java:247)
         at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl.doFilter(TrinidadFilterImpl.java:157)
         at org.apache.myfaces.trinidad.webapp.TrinidadFilter.doFilter(TrinidadFilter.java:92)
         at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
         at oracle.security.jps.ee.http.JpsAbsFilter$1.run(JpsAbsFilter.java:94)
         at java.security.AccessController.doPrivileged(Native Method)
         at oracle.security.jps.util.JpsSubject.doAsPrivileged(JpsSubject.java:313)
         at oracle.security.jps.ee.util.JpsPlatformUtil.runJaasMode(JpsPlatformUtil.java:413)
         at oracle.security.jps.ee.http.JpsAbsFilter.doFilter(JpsAbsFilter.java:138)
         at oracle.security.jps.ee.http.JpsFilter.doFilter(JpsFilter.java:70)
         at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
         at oracle.adf.library.webapp.LibraryFilter.doFilter(LibraryFilter.java:159)
         at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
         at oracle.dms.wls.DMSServletFilter.doFilter(DMSServletFilter.java:326)
         at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
         at weblogic.servlet.internal.RequestEventsFilter.doFilter(RequestEventsFilter.java:27)
         at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
         at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:3592)
         at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
         at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:121)
         at weblogic.servlet.internal.WebAppServletContext.securedExecute(WebAppServletContext.java:2202)
         at weblogic.servlet.internal.WebAppServletContext.execute(WebAppServletContext.java:2108)
         at weblogic.servlet.internal.ServletRequestImpl.run(ServletRequestImpl.java:1432)
         at weblogic.work.ExecuteThread.execute(ExecuteThread.java:201)
         at weblogic.work.ExecuteThread.run(ExecuteThread.java:173)
    Caused by: javax.faces.el.EvaluationException: java.lang.NullPointerException
         at org.apache.myfaces.trinidad.component.MethodExpressionMethodBinding.invoke(MethodExpressionMethodBinding.java:51)
         at com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:102)
         at org.apache.myfaces.trinidad.component.UIXCommand.broadcast(UIXCommand.java:190)
         at oracle.adf.view.rich.component.fragment.ContextSwitchingComponent$1.run(ContextSwitchingComponent.java:90)
         at oracle.adf.view.rich.component.fragment.ContextSwitchingComponent._processPhase(ContextSwitchingComponent.java:309)
         at oracle.adf.view.rich.component.fragment.ContextSwitchingComponent.broadcast(ContextSwitchingComponent.java:94)
         at oracle.adf.view.rich.component.fragment.UIXInclude.broadcast(UIXInclude.java:102)
         at oracle.adf.view.rich.component.fragment.ContextSwitchingComponent$1.run(ContextSwitchingComponent.java:90)
         at oracle.adf.view.rich.component.fragment.ContextSwitchingComponent._processPhase(ContextSwitchingComponent.java:309)
         at oracle.adf.view.rich.component.fragment.ContextSwitchingComponent.broadcast(ContextSwitchingComponent.java:94)
         at oracle.adf.view.rich.component.fragment.UIXInclude.broadcast(UIXInclude.java:96)
         at javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:475)
         at javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:756)
         at oracle.adfinternal.view.faces.lifecycle.LifecycleImpl._invokeApplication(LifecycleImpl.java:698)
         at oracle.adfinternal.view.faces.lifecycle.LifecycleImpl._executePhase(LifecycleImpl.java:285)
         at oracle.adfinternal.view.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:177)
         at javax.faces.webapp.FacesServlet.service(FacesServlet.java:265)
         ... 36 more
    Caused by: java.lang.NullPointerException
         at kokaugi.view.bean.ValueHolder.deleteButtonPases_action(ValueHolder.java:95)
         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
         at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         at java.lang.reflect.Method.invoke(Method.java:597)
         at com.sun.el.parser.AstValue.invoke(AstValue.java:157)
         at com.sun.el.MethodExpressionImpl.invoke(MethodExpressionImpl.java:283)
         at org.apache.myfaces.trinidad.component.MethodExpressionMethodBinding.invoke(MethodExpressionMethodBinding.java:46)
         ... 52 more

Maybe you are looking for