Error calling Method on Managed Bean from another Managed Bean

Hi
(Jdev 11.1.1.2.0)
Help please:
I have a managed bean (page flow scope) which is used by my main page for dynamic region flow navigation:
*public class RegionNavigationBean implements Serializable{*+
private String dynamicTaskFlowId = "/WEB-INF/home-task-flow-definition.xml#home-task-flow-definition";+
*public RegionNavigationBean() {*+
*public TaskFlowId getDynamicTaskFlowId() {*+
return TaskFlowId.parse(dynamicTaskFlowId);+
*public void setDynamicTaskFlowId(String taskFlowId) {*+
this.dynamicTaskFlowId = taskFlowId;+
taskFlowId property on main page def is set to +*${pageFlowScope.regionNavigationBean.dynamicTaskFlowId}*+
In a DB table (i.e. View Object on my model layer) I store a menu ID and a corresponding task_flow_id.
Then I have created an action listener class (RegionNavigationListener - page flow scope) which I link to my menu items on my main page (action listener property on menu item = +*#{pageFlowScope.regionNavigationAction.processAction}*+ )
In this action listener (processAction method), I retrieve the row set from the menu VO and find the record which matches my menu ID which caused the action event, thereby retrieving the task_flow_id which must be navigated to.
I then try to retrieve the instance of the RegionNavigationBean with the following statement: RegionNavigationBean regNav = (RegionNavigationBean)JSFUtils.getManagedBeanValue("regionNavigationBean");+
This seems to work fine, but as soon as I try and use this I get NullPointerException error, e.g.:
regNav.setDynamicTaskFlowId(menusRow.gettaskFlowId());+
or even:
System.out.println("%%% " + regNav.toString());+
This is all quite new to me... any help would be appreciated!
Thanks
Mario

Hi Mario,
I think JSFUtils.getManagedBeanValue(String) has difficult to evaluate the "regionNavigationBean" managed bean.
What JSFUtils.getManagedBeanValue(String) do is important. I remember that "JSF scoped" bean can be found by JSF style find method, such as requestScope, sessionScope, applicationScope. For a managed bean put in these scope, scope prefix is not needed, for example: using #{beanName} to locate a requestScope bean. The #{requestScope} prefix is not needed.
But pageFlowScope is different. If a bean is put in the pageFlowScope, you must use #{pageFlowScope.beanName} to locate it.
Say, ManagedBean is the java class of your manged bean.
FacesContext ctx = FacesContext.getCurrentInstance();
Application app = ctx.getApplication();
ManagedBean mb = (ManagedBean)app.evaluateExpressionGet(ctx, "#{pageFlowScope.managedBeanName}", ManagedBean.class);
Hope it helps.
Todd
Edited by: Todd Bao on Nov 26, 2009 9:58 PM

Similar Messages

  • Can I Call method on one JVM from another through a dll?

    Let me explain.
    I have this java jar file that I can only have one instance of running at any given time. I'm using a shared data segment in a dll to store a bool indicating whether the program is already running or not. If it's already running, I have to not run the second instance and give focus to the current running instance.
    The jar file calls a native method "canInstantiate()" on a dll to see if there's already an app running. If there isn't, the env and obj are stored in the shared data segment of the dll and we return true. If there is already an instance of the program running, I want canInstantiate call a function on the current instance of the jar (like a callback) to tell it to request focus. It's not working. Can someone tell me if my code is right?
    The .h file
    #include "stdafx.h"
    #include <jni.h>
    #include "CardServer.h"
    #pragma data_seg("SHARED") // Begin the shared data segment.
    static volatile bool instanceExists = false;
    static JavaVM *theJavaVM = NULL;
    static JNIEnv* theJavaEnv= NULL;
    static jobject instanceObject = NULL;
    static jmethodID mid = NULL;
    static jclass cls = NULL;
    #pragma data_seg()
    #pragma comment(linker, "/section:SHARED,RWS")
    jdouble canInstantiate(JNIEnv *env, jobject obj);
    jdouble instantiate(JNIEnv *env, jobject obj);
    jdouble uninstantiate(JNIEnv *env, jobject obj);
    void grabFocus();
    </code>
    The .cpp file:
    <code>
    #include "MyFunctions.h"
    #include <string.h>
    #include <stdlib.h>
    #include "stdafx.h"
    #include <iostream.h>
    jdouble canInstantiate(JNIEnv *env, jobject obj)
    printf("In canInstantiate!!");
    if (!instanceExists)
    printf("No instance exists!!");
    return (jdouble)0.0;
    else
    printf("An instance already exists!!");
    grabFocus();
    return (jdouble)1.0;
    jdouble instantiate(JNIEnv *env, jobject obj)
    printf("**In CPP: Instantiate!!\n");
    cout << "At start, env is: " << env << endl;
    cout << "At start, obj is: " << obj << endl;
    if (instanceExists == false)
    instanceExists = true;
    theJavaEnv = env;
    instanceObject = obj;
    theJavaEnv->GetJavaVM(&theJavaVM);
    cls = (theJavaEnv)->FindClass("TheMainClassOfTheJar");
    if (cls == 0) {
    fprintf(stderr, "Can't find Prog class\n");
    exit(1);
    mid = (theJavaEnv)->GetMethodID(cls, "grabFocusInJava", "(I)I");
    if (mid == 0) {
    fprintf(stderr, "Can't find grabFocusInJava\n");
    exit(1);
    printf("About to call grabFocusInJava\n");
    grabFocus();
    printf("CPP: After the grab focus command in instantiate!!\n");
    cout << "At end, env is: " << env << endl;
    cout << "At end, obj is: " << obj << endl;
    return 0.0;
    else
    printf("CPP: Finished Instantiate!!\n");
    return 1.0;
    jdouble uninstantiate(JNIEnv *env, jobject obj)
    printf("CPP: In uninstantiate!!\n");
    if (instanceExists == true)
    instanceExists = false;
    theJavaVM = NULL;
    instanceObject = NULL;
    printf("CPP: Finishing uninstantiate!!\n");
    return 0.0;
    else
    printf("CPP: Finishing uninstantiate!!\n");
    return 1.0;
    void grabFocus()
    printf("In CPP::GrabFocus!!\n");
    instanceObject = theJavaEnv->NewGlobalRef(instanceObject);
    cls = (theJavaEnv)->FindClass("CardFormatter");
    if (cls == 0) {
    fprintf(stderr, "Can't find Prog class\n");
    exit(1);
    printf("Got the cls id again!!\n");
    if (cls == 0)
    printf("IT'S INVALID!!\n");
    mid = (theJavaEnv)->GetMethodID(cls, "grabFocusInJava", "(I)I");
    if (mid == 0) {
    fprintf(stderr, "Can't find grabFocusInJava\n");
    exit(1);
    theJavaEnv->CallIntMethod(instanceObject, mid, 2);
    printf("Called grabFocusInJava\n");
    </code>
    thanks in advance

    Can I Call method on one JVM from another through a dll
    ...The rest of your question merely expands on your title.
    And the answer to that question is no.
    When you call a method you are executing a "thread of execution." A thread of execution exists only in a single process. It can not exist in another process.
    If the dll is doing some interesting things then you could call a method that sets a flag. Data can move between instances. But you would then have to have a thread in that different process monitoring that flag. And sharing data in a dll is not a normal process, so it would have to be coded appropriately.
    If all you want to do is set the current focus to the existing application, then that can be done with existing windows functionality. You don't need to do anything special in your dll. You can probably search these forums to find the exact code. If not there are countless examples in windows repositories (like MSDN) on how to do that.

  • Is there any way to call methods of one view from another

    Hi experts,
    I am new to webdynpro.I am having some requirement in which I need to call methods of one view from some other view of same component .So is there any way to do this.

    Dear Pradeep,
    This will solve your problem......( plz 1st read everything ..)
    There are 2 views  :
    i) Mandatory Attributes ' view(V1)
    ii) Button' s  View..(V2)
    1. Create a method in Component Controller.( M1).
    2. Goto V2 . In the Action Handler method of Button , call method  M1 of component controller.
    3. Write your Code in M1 instead of  V2 method.
    4. Create an EVENT ( E1 ) in component controller.
    5. Fire this event  from M1 before executing Action Code.
    6. Now  Add the event handler method of  E1 in  V1 ( i.e. Mandatory attributes view. )   ..........clear????? .. set "METHOD TYPE" = Event Handler. instead of  Method.
    7. In this event handler method in V1 , write the "check_mandatory_attribute_view" method.
    8. use necessary flags..
    Regards ,
    Aditya.

  • Call method with an argument from another view controller

    I have a UIViewController MainViewController that brings up a modal view that is of the class AddPlayerViewController. When the user clicks 'Save' in the modal view I need to pass the Player data (which is a Player class) from the modal view to the MainViewController in addition to triggering a method in the MainViewController. What's the best way to accomplish this? I'm new to cocoa and have only tried using delegates and some ugly hacks to no avail.
    Thanks for the help.

    If I understand correctly, you have:
    1. A model object, Player.
    2. A top view controller, MainViewController.
    3. Another view controller, AddPlayerViewController, which MainViewController displays modally.
    I'm guessing that AddPlayerViewController creates a new Player object and lets the user set its values, and you need a way to get that new Player into MainViewController once they're done.
    So, here's what I'd do:
    1. Create an AddPlayerViewControllerDelegate protocol. It should declare two methods, "- (void)addPlayerViewController:(AddPlayerViewContrller*)controller didAddPlayer:(Player*)newPlayer" and "- (void)addPlayerViewControllerNotAddingPlayer:(AddPlayerViewController*)controll er".
    2. Add an attribute of type "id <AddPlayerViewControllerDelegate>" called delegate to AddPlayerViewController. Also add a property with "@property (assign)" and "@synthesize".
    3. Modify AddPlayerViewController so that if you click the "Save" button, addPlayerViewController:didAddPlayer: gets called, passing "self" and the new Player object as the two arguments. Also arrange for clicking the "Cancel" button to call addPlayerViewControllerNotAddingPlayer:.
    4. Modify MainViewController to declare that it conforms to AddPlayerViewControllerDelegate. Implement those two methods (addPlayerViewControllerNotAddingPlayer: might be an empty method if you don't want to do anything).
    5. When you create your AddPlayerViewController, set its delegate to your MainViewController.
    If you need more detail, let me know what parts you need me to elaborate on.

  • Calling a method of one class from another withing the same package

    hi,
    i've some problem in calling a method of one class from another class within the same package.
    for eg. if in Package mypack. i'm having 2 files, f1 and f2. i would like to call a method of f2 from f1(f1 is a servlet) . i donno exactly how to instantiate the object for f2. can anybody please help me in this regard.
    Thank u in advance.
    Regards,
    Fazli

    This is what my exact problem.
    i've created a bean (DataBean) to access the database. i'm having a servlet program (ShopBook). now to check some details over there in the database from the servlet i'm in need to use a method in the DataBean.
    both ShopBook.java and DataBean.java lies in the package shoppack.
    in ShopBook i tried to instantiate the object to DataBean as
    DataBean db = new DataBean();
    it shows the compiler error, unable to resolve symbol DataBean.
    note:
    first i compiled DataBean.java, it got compiled perfectly and the class file resides inside the shoppack.
    when i'm trying to compile the ShopBook its telling this error.
    hope i'm clear in explaining my problem. can u please help me?
    thank u in advance.
    regards,
    Fazli

  • Cannot get reference to a managed bean from another

    After reading one of BlausC article:
    http://balusc.blogspot.com/2006/06/communication-in-jsf.html#AccessingAnotherManagedBean
    I always get null when I try to get a reference to a session scoped managed bean from a current bean:
    Here is part of the faces context config file:
    <faces-config>
    <managed-bean>
      <managed-bean-name>approvalManagementBean</managed-bean-name>
      <managed-bean-class>com.waseel.waseele.presentation.approval.management.ApprovalManagementBean</managed-bean-class>
      <managed-bean-scope>session</managed-bean-scope>
      <managed-property>
      <property-name>configService</property-name>
      <property-class>com.waseel.waseele.business.config.ConfigService</property-class>
       <value>#{configService}</value>
      </managed-property>
      <managed-property>
       <property-name>approvalService</property-name>
       <property-class>com.waseel.waseele.business.approval.ApprovalService</property-class>
       <value>#{approvalService}</value>
      </managed-property>
      <managed-property>
       <property-name>claimManagementService</property-name>
       <property-class>com.waseel.waseele.business.claim.management.ClaimManagementService</property-class>
       <value>#{claimManagementService}</value>
      </managed-property>
      <managed-property>
       <property-name>codedValuesLoaderServices</property-name>
       <property-class>com.waseel.waseele.business.claim.extraction.loader.codedValuesLoader.CodedValuesLoaderServices</property-class>
       <value>#{codedValue}</value>
      </managed-property>
      <managed-property>
       <property-name>approvalSubmission</property-name>
       <property-class>com.waseel.waseele.business.approval.submission.ApprovalSubmission</property-class>
       <value>#{approvalSubmission}</value>
      </managed-property>
      <managed-property>
       <property-name>payerTpaRelationService</property-name>
       <property-class>com.waseel.waseele.business.payerTpaRelation.PayerTpaRelationService</property-class>
       <value>#{payerTpaRelationService}</value>
      </managed-property>
    <managed-property>
    <property-name>payerTpaFiller</property-name>
    <property-class>com.waseel.waseele.business.payerTpaRelation.PayerTpaFiller</property-class>
    <value>#{payerTpaFiller}</value>
    </managed-property>
    </managed-bean>and part of my code:
    public String displayApprovalInEditMode()throws Exception{          
              //This is cross-managed been access; I  need to get the current Approval in the approval management been
              ApprovalManagementBean appMangBean=(ApprovalManagementBean) FacesContext.getCurrentInstance()
                                                      .getExternalContext().getSessionMap().get("approvalManagementBean");What possible problems may be?
    Can any one tell when these session managed beans object get created? is it at start up? or when loading a JSF page that use a bean ?
    becasue this code work in places while not in another

    You must be doing something wrong. I cannot reproduce this problem with the following SSCCE on JSF 1.2_13 at Tomcat 6.0.20.
    Bean1package mypackage;
    public class Bean1 {
        private Bean2 bean2;
        public boolean isBean2Present() {
            return bean2 != null;
        public Bean2 getBean2() {
            return bean2;
        public void setBean2(Bean2 bean2) {
            this.bean2 = bean2;
    }Bean2package mypackage;
    public class Bean2 {
    }JSF<%@ taglib prefix="h" uri="http://java.sun.com/jsf/html" %>
    <%@ taglib prefix="f" uri="http://java.sun.com/jsf/core" %>
    <f:view>
        <html>
            <head>
                <title>Test</title>
            </head>
            <body>
                <h:outputText value="Is bean2 present? #{bean1.bean2Present ? 'yes' : 'no'}" />
           </body>
        </html>
    </f:view>faces-config<?xml version="1.0" encoding="UTF-8"?>
    <faces-config xmlns="http://java.sun.com/xml/ns/javaee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
        xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-facesconfig_1_2.xsd"
        version="1.2">
        <managed-bean>
            <managed-bean-name>bean1</managed-bean-name>
            <managed-bean-class>mypackage.Bean1</managed-bean-class>
            <managed-bean-scope>session</managed-bean-scope>
            <managed-property>
                <property-name>bean2</property-name>
                <value>#{bean2}</value>
            </managed-property>
        </managed-bean>
        <managed-bean>
            <managed-bean-name>bean2</managed-bean-name>
            <managed-bean-class>mypackage.Bean2</managed-bean-class>
            <managed-bean-scope>session</managed-bean-scope>
        </managed-bean>
    </faces-config>It prints 'yes'.

  • Initialize a stateful session bean from another

    Hi,
    I am trying to create and initialize a stateful session bean from another stateful session bean. The code is as follows
    This method belongs to DefaultSessionBean where it creates the AdminSessionBean based on few checks and returns it to the client.
        public AdminSession getAdminSession() throws UnknownException, WarningException {
            checkSessionUser("getAdminSession");
            if (isAdmin()) {
                AdminSession adminSession;
                try {
                    final Context context = IToolsUtil.getInitialContext();
                    adminSession = (AdminSession)context.lookup("AdminSession");
                    System.out.println("Successfully created the adminsession bean");
                } catch (NamingException ne) {
                    ne.printStackTrace();
                    throw new UnknownException (new CatalogHelper("ITOOLS_100019", new Object[]{"Admin", ne.getMessage()}));
                System.out.println("adminsession will be returned");
                return adminSession;
            } else {
                throw new WarningException (new CatalogHelper("ITOOLS_000042", sessionUser.getUserhandle()));
        }Another method in DefaultSessionBean, creates its local interface and returns it.
        public DefaultSessionLocal getDefaultSessionLocal() {
            DefaultSessionLocal dsl = (DefaultSessionLocal)context.getBusinessObject(DefaultSessionLocal.class);
            System.out.println("local created.");
            return dsl;
        }Client call initialize method of the AdminSessionBean which is mentioned below:
        public void initialize(DefaultSession ds) throws WarningException, UnknownException {
            this.ds = ds.getDefaultSessionLocal();
            this.rfl = ReadFieldList.getInstance();
            this.fm = new FinderMethods();
        }The client code where it gets the adminSession and initializes is
       public static AdminSession getAdminSession(DefaultSession ds) throws ViewException {
            AdminSession as;
            try {
                as = ds.getAdminSession();
                System.out.println("got admin session");
            } catch (WarningException we) {
                 we.printStackTrace();
                throw new ViewException(we.getCatalogHelper());
            } catch (UnknownException ue) {
                ue.printStackTrace();
                throw new ViewException(ue.getCatalogHelper());
            } catch (OracleRemoteException ore) {
                ore.printStackTrace();
                throw new ViewException(new CatalogHelper("ITOOLS_050003", ore.getMessage()));
            // Initialize Admin Session
            try {
                System.out.println("before getting it.");
                as.initialize(ds);
                System.out.println("adminsession is initialized");
            } catch (WarningException we) {
                as.remove();
                as = null;
                throw new ViewException(we.getCatalogHelper());
            } catch (UnknownException ue) {
                as.remove();
                as = null;
                throw new ViewException(ue.getCatalogHelper());
            } catch (OracleRemoteException ore) {
                as.remove();
                as = null;
                throw new ViewException(new CatalogHelper("ITOOLS_050003", ore.getMessage()));
            System.out.println("got admin session");
            return as;
        }Apart from this I am using OC4J 10.1.3.1 tool test my application.
    When I am calling initialize method of the AdminSession I am getting the following error.
    06/10/24 12:26:08 Entered
    06/10/24 12:26:08 got default session
    06/10/24 12:26:08 Successfully created the adminsession bean
    06/10/24 12:26:08 adminsession will be returned
    06/10/24 12:26:08 got admin session
    06/10/24 12:26:08 before getting it.
    2006-10-24 12:26:08.156 WARNING J2EE RMI-00009 Exception returned by remote server: {0}
    06/10/24 12:26:08 com.itools.vs.view.exception.ViewException
    06/10/24 12:26:08      at com.itools.vs.view.util.ViewUtil.getAdminSession(ViewUtil.java:71)
    06/10/24 12:26:08      at com.itools.vs.view.backing.Admin.CreateUser.submit_action(CreateUser.java:182)
    06/10/24 12:26:08      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    06/10/24 12:26:08      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    06/10/24 12:26:08      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    06/10/24 12:26:08      at java.lang.reflect.Method.invoke(Method.java:585)
    06/10/24 12:26:08      at com.sun.faces.el.MethodBindingImpl.invoke(MethodBindingImpl.java:146)
    06/10/24 12:26:08      at com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:92)
    06/10/24 12:26:08      at org.ajax4jsf.framework.ajax.AjaxActionComponent.broadcast(AjaxActionComponent.java:88)
    06/10/24 12:26:08      at org.ajax4jsf.framework.ajax.AjaxViewRoot.processEvents(AjaxViewRoot.java:274)
    06/10/24 12:26:08      at org.ajax4jsf.framework.ajax.AjaxViewRoot.broadcastEvents(AjaxViewRoot.java:250)
    06/10/24 12:26:08      at org.ajax4jsf.framework.ajax.AjaxViewRoot.processApplication(AjaxViewRoot.java:405)
    06/10/24 12:26:08      at com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:95)
    06/10/24 12:26:08      at com.sun.faces.lifecycle.LifecycleImpl.phase(LifecycleImpl.java:245)
    06/10/24 12:26:08      at com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:110)
    06/10/24 12:26:08      at javax.faces.webapp.FacesServlet.service(FacesServlet.java:213)
    06/10/24 12:26:08      at com.evermind.server.http.ResourceFilterChain.doFilter(ResourceFilterChain.java:64)
    06/10/24 12:26:08      at org.ajax4jsf.framework.ajax.xmlfilter.BaseXMLFilter.doXmlFilter(BaseXMLFilter.java:67)
    06/10/24 12:26:08      at org.ajax4jsf.framework.ajax.xmlfilter.BaseFilter.doFilter(BaseFilter.java:223)
    06/10/24 12:26:08      at com.evermind.server.http.ServletRequestDispatcher.invoke(ServletRequestDispatcher.java:621)
    06/10/24 12:26:08      at com.evermind.server.http.ServletRequestDispatcher.forwardInternal(ServletRequestDispatcher.java:368)
    06/10/24 12:26:08      at com.evermind.server.http.HttpRequestHandler.doProcessRequest(HttpRequestHandler.java:866)
    06/10/24 12:26:08      at com.evermind.server.http.HttpRequestHandler.processRequest(HttpRequestHandler.java:448)
    06/10/24 12:26:08      at com.evermind.server.http.HttpRequestHandler.serveOneRequest(HttpRequestHandler.java:216)
    06/10/24 12:26:08      at com.evermind.server.http.HttpRequestHandler.run(HttpRequestHandler.java:117)
    06/10/24 12:26:08      at com.evermind.server.http.HttpRequestHandler.run(HttpRequestHandler.java:110)
    06/10/24 12:26:08      at oracle.oc4j.network.ServerSocketReadHandler$SafeRunnable.run(ServerSocketReadHandler.java:260)
    06/10/24 12:26:08      at oracle.oc4j.network.ServerSocketAcceptHandler.procClientSocket(ServerSocketAcceptHandler.java:239)
    06/10/24 12:26:08      at oracle.oc4j.network.ServerSocketAcceptHandler.access$700(ServerSocketAcceptHandler.java:34)
    06/10/24 12:26:08      at oracle.oc4j.network.ServerSocketAcceptHandler$AcceptHandlerHorse.run(ServerSocketAcceptHandler.java:880)
    06/10/24 12:26:08      at com.evermind.util.ReleasableResourcePooledExecutor$MyWorker.run(ReleasableResourcePooledExecutor.java:303)
    06/10/24 12:26:08      at java.lang.Thread.run(Thread.java:595)
    06/10/24 12:26:08 ITOOLS_050003: Failed to get Admin Session.
    Exception is "Error marshalling objects, Not Serializable: java.io.NotSerializableException: DefaultSession_RemoteProxy_6nein01; nested exception is:
         java.io.NotSerializableException: DefaultSession_RemoteProxy_6nein01".
    [b/                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

    Your remote client passes a DefaultSession to AdminSession.initialize(..). This DefaultSession has to be a remote type. In your client, how does it get DefaultSession?
    Did your client look up DefaultSession, and have it return a (sessionContext.getBusinessObject(DefaultSession.class))? If so, it should work.

  • Error calling method of a PBNI object

    Dear All,
    We are facing issue of "Error calling method of a PBNI object". We are calling web services of WCF after some time to refresh data.We need help to solve this issue as we have to go live with client.
    It's really urgent!
    Regards
    Imran Zaheer

    Hi Chris,
    Thanks for your concern.
    1) PB version & Build?
         PB builder 12.5.2 build 5609
    2) MS-Window version?
         Windows 7 professional.
    3) Why are you using PBNI and what kind of class are you utilizing in that context?
         We are calling webservices through soap objects.
    4) What error(s) codes and messages are you getting?
        we get "Error calling method of a PBNI object"
    5) Why are you not using PB.net that supports WCF natively (I wish PB classic did)?
        For this we need to convert our whole application in PB.Net which is not feasible for us.
    6) Can you lightly describe your over-all architecture and application approach to Web Services?
         We have replace EASERVER with WCFserver and we are calling webservices for fetching( pulling) data from WCF server. It's a soft of 3 tier architecture.
    Regards .... Imran

  • What is error  "Error calling method on NPObject!" ?

    I use API get mks link and submit ticket open VMRC console but console doesn't run and get this error "Error calling method on NPObject!"
    How i can fix?

    Well,
    I did that and I don't see much difference...where is the debugging suppose to be?
    anyway I use FF and Firebug and I exporting to flash player 9
    The error seems to be coming from a line of code
    function (params) {
    86        obj = FB.JSON.parse(params);
    87        cb = function (response) {FBAS.getSwf().uiResponse(FB.JSON.stringify(response), obj.method);};
    88        FB.ui(obj, cb);
    89    }
    90    function () {
    91        session = FB.getSession();
    92        return FB.JSON.stringify(session);
    93    }
    I assume that this is from the FB graph swf wrapper?
    The object in question seems to be the session I get back from facebook. The thing is I successfully get it sooo I'm kinda stumped as to what really is the problem here...

  • Error while trying to copy template from another application

    Hi,
    I am getting this error while trying to copy template from another application:
    report error:
    ORA-06502: PL/SQL: numeric or value error: character string buffer too small
    This report is located here:
    Home-Application Builder-Application 150-Shared Components-Templates-Replace Templates
    best regards,

    It is usually a permissions issue.. you have read but not write permission. Why it would suddenly change is one of those Apple Mysteries... but it happens.
    Open the directory (folder) where your media files are.. and check the permissions.. see if you can fix them.
    The problem is the folder on the TC might have lost your ownership and you might not be able to change it.. Apple do not provide anyway to regain permissions because you would need low level access to the TC firmware.
    I would just as a matter of course reset the TC to factory and redo its setup.
    Factory reset universal
    Power off the TC.. ie pull the power cord or power off at the wall.. wait 10sec.. hold in the reset button.. be gentle.. power on again still holding in reset.. and keep holding it in for another 10sec. You may need some help as it is hard to both hold in reset and apply power. It will show success by rapidly blinking the front led. Release the reset.. and wait a couple of min for the TC to reset and come back with factory settings. If the front LED doesn’t blink rapidly you missed it and simply try again. The reset is fairly fragile in these.. press it so you feel it just click and no more.. I have seen people bend the lever or even break it. I use a toothpick as tool.
    N.B. None of your files on the hard disk of the TC are deleted.. this simply clears out the router settings of the TC.
    Do the setup via airport utility using different names.. short, no spaces and pure alphanumerics. Make sure passwords are also pure alphanumeric mixed case and numbers.. 8-20 characters is usually plenty.
    Mount the disk in finder and see if you have the same issue.. I am not expecting a change.. but it is worth a try.
    No luck you can copy your files off the TC.. wipe it .. and then copy them back.. no bad thing unless you already have a backup of your files at the moment. In which case you can just wipe the TC and copy the files now.

  • Error while activating DSO after loading from another DSO..Production issue

    Hello Gurus,
    I got an error while activating DSO2 after loading from another DSO1.
    DSO1 load and activation was sucessful but while loading from DSO1 to DSO2 load was fine but got error while activating...
      >Error when assigning SID: Action VAL_SID_CONVERT table ZWEEK_NUM
      >Value u201809u2019 of characteristic ZWEEK_NUM is not a number with 000004 spaces
    this theard was posted after searching for related post in SDN.
    and i tried Function Module RSODS_CHECK_RSODSACTUPDTYPE but it is not available .. but I used this in BW 3.10u2026..
    is their any similar Function Module in BI 7.0 please advice.
    We are using SAP NetWeaver BI 7.0
    Release- 700    Service level- 017
    Thanks in advance
    Sandy

    sloved the issue......
    it was due to wrong data for the related field...
    it  must be "0009 "
    Thanks for ur support. closing the ticket
    Regards
    Sandy

  • Set value of variable in one bean from another bean

    Using JDeveloper 11.1.1.4, I thought this would be simple to do, but I haven't been able to figure out the correct syntax and am just learning java. In my view controller I have one bean set as pageflow scope, and another bean set as a request scope. How do I set the value of a variable in the first bean from the second bean? The first bean has setters and getters, but when I try to reference them in the second bean, it says it isn't allowed. The first bean looks like:
    public class ViewAmtsParameters {
        String asOfDateParam = null;
        public void setAsOfDateParam(String asOfDateParam) {
            this.asOfDateParam = asOfDateParam;
        public String getAsOfDateParam() {
            return asOfDateParam;
    }Thanks in advance,
    Troy

    for ur reference: go through entire docs.
    http://balusc.blogspot.com/2006/06/communication-in-jsf.html
    Edited by: Erp on Oct 7, 2011 9:12 PM

  • Is it possible to call methods of JAVA objects from ABAP?

    Hi all,
    Does anyone know if it is possible to call methods of java classes from ABAP?
    Regards,
    Sukru

    Hi,
    Yes we can access the classes of JAVA in ABP.
    This is posible from version ECC 6 onward with NETWEAVER atrhcitecuture.
    Pls go through this link-
    http://help.sap.com/saphelp_nw04s/helpdata/en/84/54953fc405330ee10000000a114084/frameset.htm
    http://help.sap.com/saphelp_nw04s/helpdata/en/e1/b5443e02a9ab4186a6e1240a9a2455/frameset.htm
    Here also we use the JCO connector  objects
    These clearly show the methods to use JAVA.
    <removed_by_moderator_together_with_points>
    Regards
    Chandralekha
    Edited by: Julius Bussche on Jul 8, 2008 5:58 PM

  • How do you use one managed session bean from another?

    Hello -
    I am a complete newbie to JSF coming from Struts 1. My question is how do you use one managed bean from the method of another one? I think this would be a common senario. For example I put a bean in session scope when a user logs in and in a different method within a different bean I want to get some of this user's information. What is the correct way to retireve one bean from a method in another with session scope?
    Also what would the code look like to retieve another bean from the method of a managed bean where the bean you want to retrieve has application scope?
    Thank you in advance.

    Sinplicity wrote:
    Could you be a bit more specific? If a bean is configured in the faces config file then all of it's properties are managed, correct?Not necessarily.
    What would the code look like to retireve the bean?You don't retrieve it, it has been injected.
    Can I retrieve the whole bean or just a property of the bean. I would be really interested in seeing how this is done in code? And would really love a bit more information on what it means to be a managed property?Time to consult a JSF tutorial.

  • How to call a specific method in a servlet from another servlet

    Hi peeps, this post is kinda linked to my other thread but more direct !!
    I need to call a method from another servlet and retrieve info/objects from that method and manipulate them in the originating servlet .... how can I do it ?
    Assume the originating servlet is called Control and the servlet/method I want to access is DAO/login.
    I can create an object of the DAO class, say newDAO, and access the login method by newDAO.login(username, password). Then how do I get the returned info from the DAO ??
    Can I use the RequestDispatcher to INCLUDE the call to the DAO class method "login" ???
    Cheers
    Kevin

    Thanks for the reply.
    So if I have a method in my DAO class called login() and I want to call it from my control servlet, what would the syntax be ?
    getrequestdispatcher.include(newDAO.login())
    where newDAO is an instance of the class DAO, would that be correct ?? I'd simply pass the request object as a parameter in the login method and to retrieve the results of login() the requestdispatcher.include method will return whatever I set as an attribute to the request object, do I have that right ?!!!!
    Kevin

Maybe you are looking for

  • Is there a way to keep the screensaver on?

    I have Macbook Pro from around 2008, not sure of the exact model, running 10.5.8. I have it hooked up to a large Apple Display. We're having a party tomorrow night and I'd like to leave the screensaver on a photo album of a trip to Italy that we took

  • MBP will not connect to external monitor

    I am using 13" late 2011 MacBook Pro. I used to be able to connect it to an external monitor, but recently, I have not been able to.  When I plug it into the monitor, the screen on the MBP will flicker blue and freeze, but the computer never detects

  • Device Payment Plan Experience?

    Has anyone had any experience with the Device Payment Plan which allows you to purchase a new device early without being eligible for any upgrade and pay for it monthly along with your plan over 12 months?  I am considering it but am wondering if I r

  • If it is not specified,Oracle creates one control file in a default locatio

    Hi The CONTROL_FILES parameter is not required when you create a database. If it is not specified,Oracle creates one control file in a default location,. Where oracle create contol file default in this condition Thanks

  • Apple tv mirroring stops working

    I just installed my new Bell modem SageMCom 2684 and my Apple TV mirroring stopped working properly--it freezes in less than a minute when I mirror a MacBook Pro.  My TV, Apple TV, & Bell modem are relatively close. I disabled  WMM, but no luck. I co