Error in calling method of loaded swf

I have two classes. One is loading class and another is Main2 class. Loading class is our document class of Load.fla.
The code of loading class is:
package
          import flash.display.MovieClip;
          import flash.display.SimpleButton;
          import flash.text.TextField;
          import flash.display.Loader;
          import flash.events.*;
          import flash.net.URLRequest;
          public class Loading extends MovieClip
                      private var url:String;
                      private var loader:Loader;
                      public function Loading()
                                  init();
                      private function init():void
                                  url='my_swf.swf';
                                  var request:URLRequest=new URLRequest(url);
                                  loader=new Loader();
                                  initListeners(loader.contentLoaderInfo);
                                  loader.load(request);
                      private function initListeners(dispatcher:IEventDispatcher):void
                                  dispatcher.addEventListener(Event.COMPLETE,completato);
                      public function onStartClick(event:Event):void
                                  trace("MenuStart")
                      private function completato(event:Event):void
                                  loader.contentLoaderInfo.content.addEventListener("startClick",onStartClick)
                                  addChild(loader);
                                  loader.y=10;
                                  var main2:Main2;
                                  main2=new Main2(this,MovieClip(loader.content));
And the code of Main2 class is :
package
          import flash.display.MovieClip;
          import flash.events.MouseEvent;
          import flash.events.Event;
          public class Main2 extends MovieClip
                      private var _fla:MovieClip;
                      private var mia_root:MovieClip;
                      public function Main2(fla:MovieClip,m:MovieClip)
                                  _fla=fla;
                                  mia_root=m;
                                  callClip();
                      private function callClip():void
                                  mia_root.test_mc.addEventListener(MouseEvent.CLICK, onStartClick);
                      private function onStartClick(e:MouseEvent):void
                                  trace("hi")
                                  dispatchEvent(new Event("startClick"));
Here I have loaded 'my_swf file in Loading class. Actually  there is one movie clip  in my_swf . its name is test_mc. When I press on this (test_mc) movie clip
I got trace value “hi”. But I dispatch one event startClick. I didnot listen in Loading class. How can I listen.

First, what's up with this huge font?
Second, your architecture feels convoluted and it can be simplified. But, assuming everything is OK, try this (inside function completato listener is added to the instance main2):
package
     import flash.display.MovieClip;
     import flash.display.SimpleButton;
     import flash.text.TextField;
     import flash.display.Loader;
     import flash.events.*;
     import flash.net.URLRequest;
     public class Loading extends MovieClip
          private var url:String;
          private var loader:Loader;
          public function Loading()
               init();
          private function init():void
               url = 'my_swf.swf';
               loader = new Loader();
               initListeners(loader.contentLoaderInfo);
               loader.load(new URLRequest(url));
          private function initListeners(dispatcher:IEventDispatcher):void
               dispatcher.addEventListener(Event.COMPLETE,completato);
          public function onStartClick(event:Event):void
               trace("MenuStart")
          private function completato(event:Event):void
               addChild(loader);
               loader.y = 10;
               var main2:Main2 = new Main2(this, MovieClip(loader.content));
               main2.addEventListener("startClick", onStartClick);
               addChild(main2);

Similar Messages

  • Error when calling method INIT in class cl_hrxss_rem for salary statements

    after configuring the our hrform to work with the new ess system in ecc 6.0 we configured the hrfor decision tree to $cedt$ and pointed the form variant to the edtin feature.
    Now we are getting a class error.
    com.sap.pcuigp.xssfpm.java.FPMRuntimeException: Error when calling method INIT of class CL_HRXSS_REM
         at com.sap.pcuigp.xssfpm.java.MessageManager.raiseException(MessageManager.java:111)
         at com.sap.pcuigp.xssfpm.java.MessageManager.raiseException(MessageManager.java:121)
         at com.sap.xss.hr.rep.fcrfw.FcRepFramework.reportBapiRet2Error(FcRepFramework.java:525)
         at com.sap.xss.hr.rep.fcrfw.FcRepFramework.callRfcExecAction(FcRepFramework.java:374)
         at com.sap.xss.hr.rep.fcrfw.FcRepFramework.initModel(FcRepFramework.java:292)
         at com.sap.xss.hr.rep.fcrfw.wdp.InternalFcRepFramework.initModel(InternalFcRepFramework.java:256)
         at com.sap.xss.hr.rep.fcrfw.FcRepFrameworkInterface.initModel(FcRepFrameworkInterface.java:136)
         at com.sap.xss.hr.rep.fcrfw.wdp.InternalFcRepFrameworkInterface.initModel(InternalFcRepFrameworkInterface.java:198)
         at com.sap.xss.hr.rep.fcrfw.wdp.InternalFcRepFrameworkInterface$External.initModel(InternalFcRepFrameworkInterface.java:258)
         at com.sap.xss.hr.rem2.selection.VcRem2Selection.onInit(VcRem2Selection.java:245)
         at com.sap.xss.hr.rem2.selection.wdp.InternalVcRem2Selection.onInit(InternalVcRem2Selection.java:249)
         at com.sap.xss.hr.rem2.selection.VcRem2SelectionInterface.onInit(VcRem2SelectionInterface.java:161)
         at com.sap.xss.hr.rem2.selection.wdp.InternalVcRem2SelectionInterface.onInit(InternalVcRem2SelectionInterface.java:144)
         at com.sap.xss.hr.rem2.selection.wdp.InternalVcRem2SelectionInterface$External.onInit(InternalVcRem2SelectionInterface.java:220)
         at com.sap.pcuigp.xssfpm.wd.FPMComponent.doProcessEvent(FPMComponent.java:564)
         at com.sap.pcuigp.xssfpm.wd.FPMComponent.doEventLoop(FPMComponent.java:438)
         at com.sap.pcuigp.xssfpm.wd.FPMComponent.wdDoInit(FPMComponent.java:196)
         at com.sap.pcuigp.xssfpm.wd.wdp.InternalFPMComponent.wdDoInit(InternalFPMComponent.java:110)
         at com.sap.tc.webdynpro.progmodel.generation.DelegatingComponent.doInit(DelegatingComponent.java:108)
         at com.sap.tc.webdynpro.progmodel.controller.Controller.initController(Controller.java:215)
         at com.sap.tc.webdynpro.progmodel.controller.Controller.init(Controller.java:200)
         at com.sap.tc.webdynpro.clientserver.cal.ClientComponent.init(ClientComponent.java:430)
         at com.sap.tc.webdynpro.clientserver.cal.ClientApplication.init(ClientApplication.java:362)
         at com.sap.tc.webdynpro.clientserver.session.ApplicationSession.initApplication(ApplicationSession.java:748)
         at com.sap.tc.webdynpro.clientserver.session.ApplicationSession.doProcessing(ApplicationSession.java:283)
         at com.sap.tc.webdynpro.clientserver.session.ClientSession.doApplicationProcessingPortal(ClientSession.java:733)
         at com.sap.tc.webdynpro.clientserver.session.ClientSession.doApplicationProcessing(ClientSession.java:668)
         at com.sap.tc.webdynpro.clientserver.session.ClientSession.doProcessing(ClientSession.java:250)
         at com.sap.tc.webdynpro.clientserver.session.RequestManager.doProcessing(RequestManager.java:149)
         at com.sap.tc.webdynpro.clientserver.session.core.ApplicationHandle.doProcessing(ApplicationHandle.java:73)
         at com.sap.tc.webdynpro.portal.pb.impl.AbstractApplicationProxy.sendDataAndProcessActionInternal(AbstractApplicationProxy.java:860)
         at com.sap.tc.webdynpro.portal.pb.impl.AbstractApplicationProxy.create(AbstractApplicationProxy.java:220)
         at com.sap.portal.pb.PageBuilder.updateApplications(PageBuilder.java:1246)
         at com.sap.portal.pb.PageBuilder.createPage(PageBuilder.java:354)
         at com.sap.portal.pb.PageBuilder.init(PageBuilder.java:547)
         at com.sap.portal.pb.PageBuilder.wdDoRefresh(PageBuilder.java:591)
         at com.sap.portal.pb.PageBuilder$1.doPhase(PageBuilder.java:822)
         at com.sap.tc.webdynpro.clientserver.window.WindowPhaseModel.processPhaseListener(WindowPhaseModel.java:755)
         at com.sap.tc.webdynpro.clientserver.window.WindowPhaseModel.doPortalDispatch(WindowPhaseModel.java:717)
         at com.sap.tc.webdynpro.clientserver.window.WindowPhaseModel.processRequest(WindowPhaseModel.java:136)
         at com.sap.tc.webdynpro.clientserver.window.WebDynproWindow.processRequest(WebDynproWindow.java:335)
         at com.sap.tc.webdynpro.clientserver.cal.AbstractClient.executeTasks(AbstractClient.java:143)
         at com.sap.tc.webdynpro.clientserver.session.ApplicationSession.doProcessing(ApplicationSession.java:313)
         at com.sap.tc.webdynpro.clientserver.session.ClientSession.doApplicationProcessing(ClientSession.java:684)
         at com.sap.tc.webdynpro.clientserver.session.ClientSession.doProcessing(ClientSession.java:250)
         at com.sap.tc.webdynpro.clientserver.session.RequestManager.doProcessing(RequestManager.java:149)
         at com.sap.tc.webdynpro.serverimpl.defaultimpl.DispatcherServlet.doContent(DispatcherServlet.java:62)
         at com.sap.tc.webdynpro.serverimpl.defaultimpl.DispatcherServlet.doPost(DispatcherServlet.java:53)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:760)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
         at com.sap.engine.services.servlets_jsp.server.HttpHandlerImpl.runServlet(HttpHandlerImpl.java:401)
         at com.sap.engine.services.servlets_jsp.server.HttpHandlerImpl.handleRequest(HttpHandlerImpl.java:266)
         at com.sap.engine.services.httpserver.server.RequestAnalizer.startServlet(RequestAnalizer.java:387)
         at com.sap.engine.services.httpserver.server.RequestAnalizer.startServlet(RequestAnalizer.java:365)
         at com.sap.engine.services.httpserver.server.RequestAnalizer.invokeWebContainer(RequestAnalizer.java:944)
         at com.sap.engine.services.httpserver.server.RequestAnalizer.handle(RequestAnalizer.java:266)
         at com.sap.engine.services.httpserver.server.Client.handle(Client.java:95)
         at com.sap.engine.services.httpserver.server.Processor.request(Processor.java:175)
         at com.sap.engine.core.service630.context.cluster.session.ApplicationSessionMessageListener.process(ApplicationSessionMessageListener.java:33)
         at com.sap.engine.core.cluster.impl6.session.MessageRunner.run(MessageRunner.java:41)
         at com.sap.engine.core.thread.impl3.ActionObject.run(ActionObject.java:37)
         at java.security.AccessController.doPrivileged(Native Method)
         at com.sap.engine.core.thread.impl3.SingleThread.execute(SingleThread.java:100)
         at com.sap.engine.core.thread.impl3.SingleThread.run(SingleThread.java:170)
    Thanks

    Hi,
    Maintain the EDTIN feature
    &CEDT$
    And UR problem solve

  • How to call method in another swf file

    Hi. I am at the moment making a website in Flash 8. The
    website consists of a main file with the buttons and then
    additional files for each page. Each of the buttons uses code
    similar to this:
    content.loadMovie("home page.swf");
    where content is the movieclip I am using to load the swf
    file into. In the main file I have a search box where a user can
    type some search terms. I have written some code that will search
    through the text field(s) on the page and highlight any words that
    appear matching the search terms. The only problem is that I cannot
    get to the text fields on the other files. So what I want to be
    able to do is attach some code to the search button that will call
    a method in another swf file using the parameters that I the user
    has specified in the search box. How would I go about doing this?
    Any help is much appreciated
    JM Young

    Place functions in the external swf. Then you can call them
    through the container clip
    content.yourFunction(args);
    Realize however, you cannot call code in an external swf
    until the frames with the functions are loaded. Timing would be an
    issue if the user can beat the loading clock or if you have code
    that is executed automatically after you start the load.
    So if timing becomes an issue, use MovieClipLoader and the
    onLoadInit method.

  • Error on Calling Methods Using an Object of a Class

    I keep getting the error cannot resolve variable addStud . I can't figure out why. I've created objects of classes before this way, then called methods within that class like this and it worked fine. I can't discern any difference between the syntax of the program that worked successfully and this one. I commented the parts where the error is when I tried to send a variable to a method in the class Recieve of which addStud is an object of. If you can see something that I can't I'd appreciate it. I've checked the obvious things like making sure the class name and method name is spelled the same way in both my frame and the class file.
    import java.awt.event.*;
    import java.awt.*;     /* Used by IntroTest3.java. */
    import javax.swing.*;
    public class RegFrame extends JInternalFrame
    {   // Begin class RegFrame
    static final int xOffset = 30, yOffset = 30;
         private JLabel nameLabel, displayLabel;  
         private JTextField nameField;
         private JTextArea displayText;
         private JButton addButton;
         private String name;
         private int numStu;
    public RegFrame() {     // Begin RegFrame constructor  
                  super(" Register a New Student ",
                  true, //resizable
                  true, //closable
                  true, //maximizable
                  true);//iconifiable
            //...Create the GUI and put it in the window...
            //...Then set the window size or call pack...
            setSize(400,300);        //Set the window's location.
            setLocation(xOffset, yOffset);
            Container content = getContentPane();
            setBackground(Color.white);
            content.setBackground(Color.white);
            content.setLayout( new FlowLayout());
      //*   CREATE LABELS AND TEST ENTRY FIELDS FOR REGISTERING A NEW STUDENT       *
            *  HERE IS WHERE OBJECT OF RECIEVE IS CREATED *
         Recieve addStud = new Recieve();
         nameLabel = new JLabel(" Enter student name: ");
         nameField = new JTextField(20);
         content.add ( nameLabel );
         content.add ( nameField );
         addButton = new JButton( "Add Student" );
         content.add( addButton );
         addButton.addActionListener(
              new ActionListener()
         { // Open ActionListener
              public void actionPerformed (ActionEvent e)
                   getInput();
         } // Close ActionListener
        }   // End RegFrame Constructor
    // get input
        private void getInput()
              numStu++;
              name = nameField.getText();
              JOptionPane.showMessageDialog( null, "NAME: "  + name + "\n"
                    + "Student number:"+ numStu );
                    addStud.addName( name );   /** <--- HERE IS ERROR **/
    } // End class RegFrame;This is the class:
    public class Recieve
    { // Begin class Recieve
        private double stAssign[];
        private double stLab[];   
        private double stProject[];
        private double stQuiz[];
        private double stTest[];
        private String stNames[];       
        int snc;  
    public Recieve ()
            stAssign = new double[10];
            stLab = new double[10];
            stProject = new double[10];
            stQuiz = new double[10];
            stTest = new double[10];
            stNames = new String[10];
            snc = 0;    // Student Name Counter      
    public void addName (String stName)
            stNames[snc] = stName;
            snc++;
    } // End class Recieve

    1- Add the following class variable declaration for RegFrame:
    private Recieve addStud;2- Change in the RegFrame constructor:
    addStud = new Recieve();

  • Error in Call Method 'create_dynamic_table'.

    Hi Experts,
    i am working on Dynamic ALV.I have created a Dynamic Fieldcatalog,which is storing the correct field values as per requirement.
    When I debbug the code: I get the following error when I am calling method 'create_dynamic_table'.
    "Unable to interpret "MATERIALS(000010)". Possible 10 MATERIALS(000010)"
    DATA: g_table TYPE REF TO data.
    CALL METHOD cl_alv_table_create=>create_dynamic_table
        EXPORTING
          it_fieldcatalog           = i_fieldcat
        IMPORTING
          ep_table                  = g_table.
    *    EXCEPTIONS
    *      generate_subpool_dir_full = 1
    *      OTHERS                    = 2.
    Please advice how do I approach this error.Is some change required in  my piece of code?
    Thanks.

    Hi Marcin,
    Thanks for all the help,finally solved the issue.I made a small error while coding the Fieldcatalog:
    now the changed code looks like the following code:
    LOOP AT i_tckh3 INTO w_tckh3.
          LOOP AT i_tckh1 INTO w_tckh1 WHERE elemt = w_tckh3-elemt.
            lcount = lcount + 1.
            WRITE w_tckh1-txele TO w_fieldcat-seltext   LEFT-JUSTIFIED.
            CONCATENATE 'KST' w_tckh3-el_hv INTO w_fieldcat-fieldname.
            TRANSLATE w_fieldcat-fieldname              TO UPPER CASE.
            w_fieldcat-col_pos   =  lcount.
            w_fieldcat-ref_field = 'KST001'.
            w_fieldcat-ref_table = 'KEPH'.
            w_fieldcat-datatype  = 'CURR'.
            APPEND w_fieldcat TO i_fieldcat.
            CLEAR  w_fieldcat.
            CLEAR: w_tckh1.
          ENDLOOP.
          CLEAR:w_tckh3.
        ENDLOOP.
    Emphasis on the COncatenate statement in the loop.Earlier I was passing the TXELE field to fieldname,which was wrong.
    Thanks a Ton!!!!
    I have a small dount in the next step:While assigning the values to the final internal table:
    LOOP AT i_final INTO w_final.
        ASSIGN COMPONENT 'WERKS' OF STRUCTURE <i_value> TO <fs1>.
        <fs1> = w_final-werks.
        ASSIGN COMPONENT 'MATNR' OF STRUCTURE <i_value> to <fs1>.
        <fs1> = w_final-matnr.
         LOOP AT i_keph INTO w_keph WHERE kalnr = w_final-kalnr.
          ASSIGN COMPONENT  'KST001' OF STRUCTURE <i_value> TO <fs1>.
          <fs1> = <FS1> + w_keph-kst001.
        ENDLOOP.
        APPEND <i_value> TO <i_table>.
        CLEAR: <i_value>.
      ENDLOOP.
    Now the LOOP AT I_KEPH: has all the values of the cost fields.I need to assign the appropriate value of KSTXXX to the corresponding Dynamic fieldcatalog:What should the procedure be.I am NOT able to check what values are there in dynamic calatog.
    Hope this point is not too confusing.

  • Calendar invitation errors: cannot call method 'index of' of undefined

    I added an event to iCal and it sent out some email invitaions. When people click "Accept" in their emails, they get this eror "an error has occurred which prevents application from running: cannot call method 'indexOf' of undefined". Anyone know what's going on here?

    Roginator,
    I too have been experiencing this in the past couple of days.  We have two iPhones (4s), and my wife and I add each other to our schedules.  We have tried at least 5 tests recently, and only 1 worked.  The error occurs in Safari on the iphone and also in my web browsers -Chrome, IE, and Firefox.
    Can we get someone from Apple, on the iCloud side involved with this ASAP.  I am sure many others are experiencing this.
    Thanks.

  • Error when calling method with a return of double in j2me

    hello all,
    i have following problem with a j2me program:
    if i call a method with a return of double, then i get following error
    message:
    ERROR: floating-point constants should not appear
    Error preverifying class test.hallo
    what i'm doing wrong
    thanks in regard
    ----------------example----------------------------
    double yourValue(int y, int m, int d)
    double v = 0.10;
    v = 3.39 y m *d
    return v;
    public void startApp()
    int td;
    int y =2;
    int m =2;
    int d =2;
    td = yourValue(y,m,d);
    return(td);

    It's true for MIDP 1.0.
    But you can always use implementation of the float
    point arithmetic which was written by independent
    developers. For example see J2ME section of my
    homepage http://henson.newmail.ru
    anyway, double is reserved word in java, the way you wrote the source code in your example neither the preverifier nor the compiler will recognize that you intend to use your own types for double and float. maybe with Double or Float it would be different ...
    further question: you declare a void function, in the body, however, you try to return some value. something wrong with this function??
    regards
    bernard

  • Error when calling method on EJB

    Hi,
    I have the following problem:
    From my action class I'm calling a method on EJB through Business Object and getting the following error:
    org.apache.struts.action.RequestProcessor Unhandled Exception thrown: class gov.nyc.fisa.wbas.exceptions.ServerException
    [3/6/08 13:53:44:700 EST] 1acdd938 WebGroup E SRVE0026E: [Servlet Error]-[SERVER EXCEPTION CALLING searchBenefitGroups() METHOD ]: gov.nyc.fisa.wbas.exceptions.ServerException: SERVER EXCEPTION CALLING searchBenefitGroups() METHOD
    The following are parts of my code:
    In Action Class:
    BenefitGroupBO bo = new BenefitGroupBO();
    BenefitGroupsColView cView = new BenefitGroupsColView();
    try{
        cView = bo.searchBenefitGroups(transferObject,true);
    catch (ServerException e){
        throw new ServerException("SERVER EXCEPTION CALLING searchFunds() METHOD ",e);
    In Business Object:
    private BenefitGroupImpl benGrpImpl = null;
        try{
               System.out.println("1. BenefitGroupBO - searchBenefitGroups()");
               collectionView = benGrpImpl.searchBenefitGroups(transferObject, isSearch);
               System.out.println("2. BenefitGroupBO - searchBenefitGroups()");
    catch (RemoteException e){
                throw new ServerException("Remote exception calling BenefitGroupImplBean: searchBenefitGroups()", e);
    .....It never executes the second print statement in the method
    In Remote Interface:
    public BenefitGroupsColView searchBenefitGroups(BenefitGroupVO transferObject, boolean isSearch)
                                                                           throws ServerException, java.rmi.RemoteException;
    In the EJB
    public BenefitGroupsColView searchBenefitGroups(BenefitGroupVO transferObject, boolean isSearch){
                                                                        throws ServerException                
             System.out.println("1. BenefitGroupImplBean - searchBenefitsGroups() method");
             BenefitGroupsColView collectionView = new BenefitGroupsColView();
             System.out.println("2. BenefitGroupImplBean - searchBenefitsGroups() method");
              return collectionView;
    .....It never executes first Print statement in that method and I do not think it ever goes into the actual EJB class.
    Can anyone tell me what am I doing wrong?
    Thank you

    Hi
    BenefitGroupBO bo = new BenefitGroupBO();
    BenefitGroupsColView cView = new BenefitGroupsColView();
    try{
        cView = bo.searchBenefitGroups(transferObject,true);
    catch (ServerException e){
        throw new ServerException("SERVER EXCEPTION CALLING searchFunds() METHOD ",e);
    How are you trying to catch Exception within try{ } ? Because as i know usage is try { }catch (Exception e) { } Could you send full code?
    Bye.

  • Calling methods in embedded SWF

    In an AIR application, I embed other Flex apps [SWFs] as part
    of the main AIR app.
    Embedding works like a charm, but I need to interact between
    the master and the (generic) slaves [the embedded SWFs].
    As far as I understand the docs, master and client can't
    exchange methods. Do I understand the docs correctly?
    If master and client can't exchange methods, I may provide
    two bindable properties in the client:
    quote:
    [Bindable]
    public var inChannel:*;
    [Bindable]
    public var outChannel:*;
    In case the master wants the client to perform an action, I
    assign the client's inChannel, which in turn fires a handler inside
    the client. If the client finished its work, it in turn assigns a
    return value to outChannel. This then fires a handler in the
    master.
    Any ideas, if this strategy is OK? Or should I manage this
    situation in some other way?
    Thx,
    Stefan

    "justria" <[email protected]> wrote in
    message
    news:g81j07$hv4$[email protected]..
    > Here is how I load widgets:
    >
    >
    quote:
    var loaderContext: LoaderContext = new LoaderContext();
    > loaderContext.allowLoadBytesCodeExecution = true;
    >
    > aLoader = new SWFLoader();
    > aLoader.source = bytes;
    > aLoader.loaderContext = loaderContext;
    >
    > ww = new CFlexletContainer();
    > ww.inner = aLoader ;
    >
    > mainGrid. addChild( ww );
    >
    >
    > Then, this fails:
    >
    >
    quote:
    aLoader2.inChannel = 'Hello';
    http://www.cflex.net/showFileDetails.cfm?ObjectID=690&Object=File&ChannelID=1

  • Can I Capture Javascript Calls from a Loaded SWF?

    My scenario:
    My main movie (SWF A) loads another movie (SWF B) and plays it.
    SWF B is legacy content - I can't modify it.
    SWF A is AS3. SWF B might be AS2 or AS3
    SWF B makes several calls to a javascript function that would normally reside in the hosting web page.
    The javascript calls might use ExternalInterface, or they might use getURL(javascript: xxx) or they might even use fscommand.
    My questions:
    Is there any way I can intercept the javascript call in movie A? I don't want to have to resort to the browser, so simply using ExternalInterface or similar to pipe the request back into the movie won't work.
    If there is a way, how does it vary across the different versions (ie. what's the difference between the child movie being AS2 or AS3, and what's the difference between the various means of calling js?
    I'm working on a web deployment, using Flex 4.0. I would be interested also in whether this is possible in Air, or Air Mobile.
    Many thanks in advance for any replies.
    JcFx
    http://www.jcfx.eu

    no, not with all those constraints.

  • Error in calling method ?

    Class Student has feilds(Name,Address,ID)
    Class addmisions is to add and delete instances of Student from an arrayList
    I get the following error message on this line- if(s.getID().equal(id))
    Addmisions.java:43: cannot find symbol
    symbol : method getID()
    location: class Student
    if(s.getID().equal(id))
    (I am a begginer) My question is do I have to write a Method named getID in the class Student or Addmisions? If so How is that written ?
    Here are my classes... Student & Addmisions
    import java.util.Date;
    public class Student
    Name name;
    Address addr;
    String ID;
    Date date;
    Student(Name n,Address a,String id)
    { name = n;
    addr = a;
    ID = id;
    date = new Date();
    // name.getLastName();
    import java.util.ArrayList;
    public class Addmisions
    ArrayList list; //member variables
    int index;
    Addmisions() //constructor
    list = new ArrayList();
    void add(Student s) //methods
    list.add(s);
    boolean Empty()
    {return list.isEmpty();
    int getindex()
    return index;
    Object removeItem (int i)
    return list.remove(i);
    boolean inList(String id)
    int i = 0;
    boolean found = false;
    while(i<list.size() && !found)
    { Object o = list.get(i);
    if (o instanceof Student)
    {  Student s = (Student)o;
    if(s.getID().equal(id))
         { found = true;}
         else i++;      
         }// if o
    }//while
    index = i;
    return found;
    }//inList
    } //addmision

    SAME QUESTION FORMATTED....
    Class Student has feilds(Name,Address,ID)
    Class addmisions is to add and delete instances of Student from an arrayList
    I get the following error message on this line- if(s.getID().equal(id))
    Addmisions.java:43: cannot find symbol
    symbol : method getID()
    location: class Student
    if(s.getID().equal(id))
    (I am a begginer) My question is do I have to write a Method named getID in the class Student or Addmisions? If so How is that written ?
    Here are my classes... Student & Addmisions
    import java.util.Date;
    public class Student
    Name name;
    Address addr;
    String ID;
    Date date;
    Student(Name n,Address a,String id)
    { name = n;
    addr = a;
    ID = id;
    date = new Date();
    // name.getLastName();
    import java.util.ArrayList;
    public class Addmisions
    ArrayList list; //member variables
    int index;
    Addmisions() //constructor
    list = new ArrayList();
    void add(Student s) //methods
    list.add(s);
    boolean Empty()
    {return list.isEmpty();
    int getindex()
    return index;
    Object removeItem (int i)
    return list.remove(i);
    boolean inList(String id)
    int i = 0;
    boolean found = false;
    while(i<list.size() && !found)
    { Object o = list.get(i);
    if (o instanceof Student)
    { Student s = (Student)o;
    if(s.getID().equal(id))
    { found = true;}
    else i++;
    }// if o
    }//while
    index = i;
    return found;
    }//inList
    } //addmision>

  • CALL METHOD ABAP run SQL wrong

    Dear All
             I have a problem in ABAP connect SQL,Below is my code snippet sentence.
    CONCATENATE 'Insert Into [timportcortrol]'
                    '(zucode,zstate,zdate,zkind) Values('''
                      VG_PCID ''','''
                      '1'','''
                      SY-DATUM ''','''
                      '1' ''')'
                     INTO SQL.
        CALL METHOD OF REC 'Execute'
         EXPORTING #1 = SQL
         #2 = CON
         #3 = '1'.
    IF NOT SY-SUBRC = 0.
        MESSAGE I000 WITH 'Download  to [timportcortrol] failure,Please Check the SQL Connect!!! '.
        EXIT.
      ENDIF.
    Con:is the connect SQL String ,the connect SQL is Okay.
    I debug this code,when I used u2018Select u2026sentenceu2019,the program can work.if I  use u2018insert intou2019 then canu2019t work,but I copied the SQL of the u2018inset Into sentenceu2026u2019run it into SQL server then it can work also.
    And I found the SY-SUBRC eq u20182u2019.whatu2019s mean about of the sy-subrc eq u20182u2019.
    I think the insert into sentence in abap I have write the wrong ,but I canu2019t assurance.
    The Insert Into Sentence is:u2019 Insert Into [timportcortrol](zucode,zstate,zdate,zkind) Values('20080807094713','1','20080807','1')u2019
    Could you give me some advice for this issue?
    Thanks of all
    Sun.

    Have you checked whether it's a problem with mixed case?  Some SQL dialects are case sensitive.
    The not very helpful meanings of the sy-subrc value can be found in ABAP help.
    0 Successful processing of the method meth.
    1 Communication Error to SAP GUI.
    2 Error when calling method meth.
    3 Error when setting a property.
    4 Error when reading a property
    matt

  • Calling method from SWF file wtih javascript, when swf file is not loaded in any browser

    Hi There,
    I have a question regarding flex and javascript integration:
    1. We have created certain components and bundle them in swf. these swf file uses webservice to connect to backend code written in java.
    2. We have deployed swf file and backend on the same tomcat server.
    3. Backend server send some datapoint to UI and plot graph and displyaed to user.
    4. Now if user generate graph from datapoint and want to export it, we are tranferring image of that graph from UI to backend. No issues in this process.
    5. Now the question is. let say user has not open any swf file in browser and backend scheduling job want to generate the graph. How we will connect to swf file.
    6. Is ther any way we can connect or call method of swf from java/jsp/html/javascript code in this scenario without loading swf file in browser??
    Please help me!!!
    Thanks
    Sonu Kumar

    Both test sites work just fine for me.
    The "Update plugin" message is exactly what would be displayed if no .swfobject file at all was found... so it may not be the "version11" thing but rather, perhaps something else is messed up with the .swfobject file.
    File can be found in both folders:
    http://www.pureimaginationcakes.com/test/Scripts/swfobject_modified.js
    http://www.pureimaginationcakes.com/Scripts/swfobject_modified.js
    and file does download when downloading the html page (just check the cache).... but for some reason it doesn't seem to be working.... Hummmmm????
    Adninjastrator

  • Calling functions / setting variables in loaded SWF

    You know how you can create a Movieclip object, add a
    function or variable to it, then call that function or change that
    variable from within the SWF that includes it? I wanna be able to
    do that, only with SWFs that are loaded at run time.
    My "main" SWF is simply a menu-type thing. The user clicks a
    button in my MAIN.SWF, and the MAIN.SWF then loads the SWF that's
    associated with that button, using the AS 3.0 prescribed
    Loader()-URLRequest()-addChild() method that everyone always asks
    about.
    This works great. But now I've got some custom objects and
    such (ie., not just strings) within my MAIN.SWF that I'd like to be
    able to share with the loaded SWFs. Preferably, I'd like to use an
    accessor-type function (ie.,
    LoadedSWF.GiveMeTheCoolObject(MyCoolObject);), though at this point
    I'm willing to hack into the object itself (ie.,
    LoadedSWF.CoolObject.CoolField = MyCoolObject.CoolField;) if that's
    what it takes.
    I've tried just calling the functions and setting the fields,
    but the AS 3.0 compiler doesn't care for that sort of nonsense on
    it's generically-defined objects. Notice also that, at run time, a
    call to LoadedSWF.hasOwnObject("GiveMeTheCoolObject") returns true.
    So my big-brained colleagues, what's the magic?
    In advance, thanks for the help!
    Scott

    Kglad,
    quote:
    Originally posted by:
    kglad
    from that error message it appears your function is expecting
    a member of the MyCoolObject class, correct?
    and MyCoolObject is not an instance of that class. so, you
    need to fix that. ie, create a member of that class and use that
    class member as the function parameter.
    Heh, that's what the error message says all right. But the
    object actually IS a MyCoolObject class object. I stared at this
    thing for hours, and MyCoolObject IS an instance of that class. I
    tried various casting combinations (including casting it to an
    Object and passing that) but had no luck whatsoever.
    So I googled this particular runtime error message ("Error
    #1034: Type Coercion failed: cannot convert ") and found a ton of
    links to other people having a similar issue. Typically, the
    problem was just as you said, someone passing a button as a string,
    that kinda thing. But one guy had a problem with an object he
    derived from the Event class. After hours spent trying to get it to
    work, he tried overriding the base class' clone() method and got it
    to work:
    http://www.asserttrue.com/articles/2006/10/14/custom-events-in-actionscript-3-0
    As for my project, I took a long hard look at the overall
    architecture of my project and decided that it was best if all the
    "real work" took place in the MAIN.SWF file. This approach would
    solve a couple of other problems, and it just makes sense in a
    "separate the display from the data" mentality.
    So (and this is the interesting part) I changed the API for
    the LOADED.SWF to accept String pairs (ie.,
    LoadedSWF.AddToDisplay(Name:String, Data:String) ) instead of
    accepting MyCoolObj. Ran it, and Viola, now we're working without
    any run time exceptions. After that glorious moment, I created a
    couple of other APIs that just accepted base classes (one an int
    type, the other a function type) and was happily on my way.
    From this, I gather that passing non-base class (ie, derived
    class) objects to loaded MovieClips via custom function APIs is...
    maybe not as straightforward as we'd expect. In the grand scheme of
    things though, not a big deal: As far as I'm concerned AS3 rocks.
    Again Kglad, thanks for all the help: Your input on how to do
    this was the big push that I needed to get over the last technical
    hurdle of this project.
    To those who are reading this topic for the "how do I call
    functions and/or set variables in a loaded SWF?"
    The short answer is to cast the loaded SWF's content object
    as a MovieClip and then call the function or alter the variable:
    //Load the SWF (you've seen this code a million times)
    var LoadedSWFObj:Loader = new Loader();
    var MyURL:URLRequest = new URLRequest("LoadThisSWF.SWF");
    LoadedSWFObj.load(MyURL);
    //This is within your Event.COMPLETE handler:
    //Cast it as a MovieClip object and work with that.
    var LoadedSWF:MovieClip = LoadedSWFObj.content as MovieClip;
    // or another way to cast it is:
    var LoadedSWF:MovieClip = MovieClip(LoadedSWFObj.content);
    //Call yer function:
    LoadedSWF.CallMe();

  • FATAL ERROR in native method: JNI call made with exception pending

    Hi everyone,
    I am trying to resolve this error exhaustively for the last 3 days.
    I have a 3rd Party DLL library which i am supposed to use from my Java Application. I compiled my own DLL that links(calls methods) the Java code and the the 3rd party DLLs.
    It works fine in my machine and 2 of my other colleagues but does work for the QA tester. The JVM crashes when it comes to the point of loading the DLL with the exception mentioned above.
    For the QA tester, a version of the DLL made in VC7.1 works fine, but the one we are trying to load was made in VC80.
    It also has the dependency dll like msvcr80.dll and msvcp80.dll
    We both have Windows XP and same the JVM (1.4)
    Please Help !!!!!!!
    Thanks,
    Zuber

    I would suggest further investigation of dependencies. If the QA machine doesn't have VC 8 check what the diffs are there.
    Jim

Maybe you are looking for