How can i call a taskflow methode from backing bean ??

Build JDEVADF_11.1.1.3.PS2_GENERIC_100408.2356.5660
i like to call a Methode (taskflow) from backing bean!
my bean code :
    public void imageLinkActionListner(ActionEvent actionEvent) {
        String              id      = actionEvent.getComponent().getId();
        int                 linkID  = Integer.parseInt(id.substring(4));
        DCBindingContainer  bc      = (DCBindingContainer)ADFUtils.getBindingContainer();
        DCTaskFlowBinding   tf      = null;
        System.out.println("Region Change...."+id+" INT "+linkID);
        switch (linkID) {
            case LINK_CALENDAR_REGION:
                tf = (DCTaskFlowBinding)bc.findExecutableBinding("calendartaskflowPage");                   
            break;
            case LINK_MAIL_REGION:
                tf = (DCTaskFlowBinding)bc.findExecutableBinding("mailtaskflowPage");                   
            break;
          case LINK_ADDRESS_REGION:
              tf = (DCTaskFlowBinding)bc.findExecutableBinding("addresstaskflowPage");                   
          break;
          case LINK_BLOGS_REGION:
              tf = (DCTaskFlowBinding)bc.findExecutableBinding("blogstaskflowPage");                   
          break;
          case LINK_MAPS_REGION:
              tf = (DCTaskFlowBinding)bc.findExecutableBinding("mapstaskflowPage");                   
          break;
        default:
            return;
        if (tf != null){
            uiMainRegion.setRegionModel(tf.getRegionModel());
            uiMainRegion.setValue(tf.getRegionModel());
            tf.getExecutableBindings();
            AdfFacesContext.getCurrentInstance().addPartialTarget(uiMainRegion);
    }i like to call *#{backingBeanScope.mapBean.initMap}*
my taskflow source
<?xml version="1.0" encoding="windows-1252" ?>
<adfc-config xmlns="http://xmlns.oracle.com/adf/controller" version="1.2">
  <task-flow-definition id="map-task-flow">
    <default-activity id="__1">map</default-activity>
    <view id="map">
      <page>/map/map.jsff</page>
    </view>
    <method-call id="initMap">
      <method>#{backingBeanScope.mapBean.initMap}</method>
      <outcome id="__7">
        <fixed-outcome>init</fixed-outcome>
      </outcome>
    </method-call>
    <control-flow-rule id="__2">
      <from-activity-id id="__3">initMap</from-activity-id>
      <control-flow-case id="__5">
        <from-outcome id="__6">init</from-outcome>
        <to-activity-id id="__4">map</to-activity-id>
      </control-flow-case>
    </control-flow-rule>
    <use-page-fragments/>
  </task-flow-definition>
</adfc-config>

Hi,
to call the bean, use the EL in Java and reference #{backingBeanScope.mapBean.initMap} as a method expression. If you try and access the bean directly then chances are that the instance is not available. Using EL from Java always guarantees this
Frank

Similar Messages

  • How can I call  a component method from OCAP ?

    I'll try to invoke Cold Fusion Component from Xlet (OCAP App), specifically I wan to invoke a query from Component(CFC) method.
    Somebody knows how to... or any idea or comments.
    Thank you so much!

    Actually, as long as the servlet returns valid javascript, you can indeed "call it" from the client. It will initiate a request and return the result to the browser.
    This example uses Perl, but it could be easily modified to go to a servlet instead.
    Note that it is only supported in DOM browsers (IE6+/NN6+/etc)
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" "http://www.w3.org/TR/REC-html40/loose.dtd">
    <html>
    <head>
    <title> Test server-side JS </title>
    </head>
    <body>
    <script type="text/javascript">
    function checkIt(variable, value)
    var newScript = "cgi-bin/validateJS.cgi?"+variable+"="+value;
    var body = document.getElementsByTagName('body').item(0)
    var scriptTag = document.getElementById('loadScript');
    if(scriptTag) body.removeChild(scriptTag);
    script = document.createElement('script');
    script.src = newScript;
         script.type = 'text/javascript';
         script.id = 'loadScript';
         body.appendChild(script)
    </script>
    <p>Test.</p>
    <form id="f1" action="">
    <input type="text" name="t1" id="t1" onChange="checkIt(this.name, this.value)">
    </body>
    </html>
    validateJS.cgi
    #!/opt/x11r6/bin/perl
    use CGI qw(:all);
    my @valArray = split(/=/,$ENV{QUERY_STRING});
    print "Content-type: text/javascript\n\n";
    # myPass is the password
    $myPass = "foobar";
    if ("$valArray[1]" eq "$myPass")
    print "alert(\"Success!!\")";
    else
    print "alert(\"Failure!!\")";

  • How can I call a servlet method from a javascript function

    I want to call l a servlet method from a javascript function.
    Does any one have an example of code.
    Thinks in advance

    Actually, as long as the servlet returns valid javascript, you can indeed "call it" from the client. It will initiate a request and return the result to the browser.
    This example uses Perl, but it could be easily modified to go to a servlet instead.
    Note that it is only supported in DOM browsers (IE6+/NN6+/etc)
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" "http://www.w3.org/TR/REC-html40/loose.dtd">
    <html>
    <head>
    <title> Test server-side JS </title>
    </head>
    <body>
    <script type="text/javascript">
    function checkIt(variable, value)
    var newScript = "cgi-bin/validateJS.cgi?"+variable+"="+value;
    var body = document.getElementsByTagName('body').item(0)
    var scriptTag = document.getElementById('loadScript');
    if(scriptTag) body.removeChild(scriptTag);
    script = document.createElement('script');
    script.src = newScript;
         script.type = 'text/javascript';
         script.id = 'loadScript';
         body.appendChild(script)
    </script>
    <p>Test.</p>
    <form id="f1" action="">
    <input type="text" name="t1" id="t1" onChange="checkIt(this.name, this.value)">
    </body>
    </html>
    validateJS.cgi
    #!/opt/x11r6/bin/perl
    use CGI qw(:all);
    my @valArray = split(/=/,$ENV{QUERY_STRING});
    print "Content-type: text/javascript\n\n";
    # myPass is the password
    $myPass = "foobar";
    if ("$valArray[1]" eq "$myPass")
    print "alert(\"Success!!\")";
    else
    print "alert(\"Failure!!\")";

  • How can i call a main method  from a different class???

    Plzz help...
    i have 2 classes.., T1 and T2.. Tt2 is a class with a main method....i want to call the main method in T2......fromT1..is it possibl..plz help

    T2.main(args);

  • How to directly call business object class from backing bean class

    I woul like to call business object class directly from the backing bean class and implement methods in BO. If possible can anyone give an example code.
    Thanks in advance

    Which problems are you occurring then? I really don't see problems. You're just free to access and invoke them.

  • Can we call a javascript function from backing bean class?

    I have a requirement. In a multiselect table, when users selects some rows and clicks a button. Depending upon some condition, an alert box should appear with 2 buttons 'Yes' and 'No'. On clicking yes, certain field values in the selected rows of table should change. On clicking no, the alert box should close. As far as i know alert box can be done only in JS.
    Please help me, if a javascript function can be called in backing bean method or suggest some way where alert boxes can appear through ADF.

    I need to go back to the backing bean as i need to iterate through each selected row of the table in a method( method written for command button) and then if atleast one of the selected rows has job field='Manager', then an alert box needs to be displayed. If none of the rows have job field as 'manager', alert box should not be displayed.
    If I write the function for onclick, i cannot iterate through the selected rows of the table in JS function.
    Please suggest a way to do this.

  • How can I call the create method in BO from Application Service

    Hello!
    When I create a Business Object, CAF generates some methods automatically.
    How can I call the create method in the BO from Application Service logic?
    When i call the method then the entityManager and the sessionContext is NULL.
    How can I initialize this?
    Can anybody help me?
    Thanks, Thomas

    If you are using CE 7.11...
    1) In the Application Services, add the BO as dependant object in dependencies tab.
    2) In the implemention, add the following codes to call create method of the BO:
    this.get<BO>.createMethod();
    julius

  • How can i call mouse click event from keypress event???

    How can i call mouse click event from keypress event???
    I want same GUI changes to be occured at key press.....i.e . button going down & comming up.....
    for calculator

    Put all the code that happens on those events into a method. Then call that method from both events.

  • How can I call a plsql function from an attribute?

    I have an attribute defined in an element. I want execute a PLSQL function from the attribute, and display the returne value with an HTML template.
    I've defined the attribute's type like PLSQL, and I've put the called of the function in the value of the attribute, but it doesn't work. The only value I obtain is an URL (I think that is the URL of the function or someting like this).
    How can I call to my function from the attribute and display the returnes value in the page?
    Thanks.

    Thanks, but it doesn't work. I have an attribute called ID_BOL and I want to associate a sequence to that attribute. I've created a function, with the sequence. This function return de value of the sequence. I want taht the attribute takes the value of the sequenece dinamically.
    I've tried it, creating the type attribute like PLSQL, and calling the function from the attribute, but it doesn't work.
    How can I return the sequence value to my attribute?
    Thanks.

  • Can any one tell me how can i call a shell script from pl/sql

    i like to call shell script from pl/sql procedure.
    can any one suggest how can i do this

    Have you not mastered in asking the same kind of question ?
    First do write a script...
    no one will spoon feed you.
    How can i call a shell script from procedure
    How to call Shell Script from pl/sql block
    -Sk

  • How can i call a shell script from procedure

    I have a shell script.now i am i a situation to call that shell script from one of my procedures and need to get a value from that script.
    can u suggest me that how can a call the shell script from pl/sql?

    Is the same question you asked here
    How to call Shell Script from pl/sql block
    -SK

  • How can i call Apple in usa from Egypt to buy an iPhone from Apple store please who khnow the contacting number answer me :)

    how can i call Apple in usa from Egypt to buy an iPhone from Apple store please who khnow the contacting number answer me

    http://www.apple.com/eg/buy/
    There are three companies linked to towards the bottom right to purchase an iPhone from. Above those three is Arab Business Machine. Choose one, or check each one out.

  • How can i call forpro prg file from java

    Hai friends,
    I have a doubt,clear it.
    how can i call forpro prg file from java file
    by,
    N.Vijay

    Thanks to your reply,
    I have some print statements in my foxpro program file.
    Then i like to invoke that foxpro file from my java file
    This want i want..,
    by,
    N.Vijay

  • Can we call a task-flow from a bean in adf?

    Sir,
    Can we call a task-flow from a bean in adf?
    Regards

    you can do this using taskflow call activity
    check - Oracle ADF World: ADF Task Flow Call Activities
    http://docs.oracle.com/cd/E24382_01/web.1112/e16182/taskflows_activities.htm#ADFFD21945
    you can pass input parameter map and dynamic taskflow reference from managed bean
    check -https://blogs.oracle.com/DavidGiammona/entry/dynamically_assign_task_flow_c
    Or if you want to use dynamic region to swich between taskflows
    see- Zeeshan Baig's Blog: Working with Dynamic Regions in Oracle ADF
    Ashish

  • How to call a Javascript function from backing bean without any event

    Hi,
    Someone knows how to call a Javascript function from backing bean without any event ?
    thanks

    Please review the following thread:
    ADF Faces call javascript
    Luis.

Maybe you are looking for

  • Flashback transaction query output

    Hi there, Here is my small demo. C:\Documents and Settings\Aman>net start oracleserviceorcl The OracleServiceORCL service is starting............................. The OracleServiceORCL service was started successfully. C:\Documents and Settings\Aman>

  • Can you tell the version of iPad from the model #?

    Can you tell the version of iPad from the model #?  If so, what is model MD329LL ?

  • 4.0 Update for Iphone 3G

    The update took me over 4hrs to complete, it took most of that time to back up my files, when I havent even used not even 1/4 of the available space on the phone. They really need to make another update so that we can have the same features as the 3G

  • Recents "All or Missed" not showing up in iOS 7

    Ever since updating to iOS 7, no calls, incoming, missed, outgoing, etc. none are showing up in the Recents section of the phone app. It's just a blank screen with lines. Any advice?

  • Yet Another modelsUnderRay Problem!

    Hi, I've seen a few posts about using the modelsUnderRay for collision detection but none of them have seem to help me. I've got a complex scene and adding collision detection to my character. However for some reason director crashes when I render th