How to Call Methods in Ecatt?

Hello Gurus,
I dont find CALLMETHOD or CALLSTATIC commands in Ecatt. I am using R/3 4.7 version of SAP.
My question also is how to call methods. I have a scenario where my test script execution depends on the return type of method. Say if the return type of method is A only then I should run the script else the script should not be executed.
Your help in this regard is highly appreciated.
Regards,
GS.

>
Get Started wrote:
> Hello Gurus,
>
> I dont find CALLMETHOD or CALLSTATIC commands in Ecatt. I am using R/3 4.7 version of SAP.
>
> My question also is how to call methods. I have a scenario where my test script execution depends on the return type of method. Say if the return type of method is A only then I should run the script else the script should not be executed.
>
> Your help in this regard is highly appreciated.
>
> Regards,
> GS.
Hi GS,
Please use the command "CallMethod" and it is available with latest SAP version.
You have to provide the Object Instance Parameter and Instance Method.
Regards,
SSN.

Similar Messages

  • How to call method of Component A in Component B

    Hi Friends,
    I want to use Method A of Component A in Component B. Can some one tell me how to call method A on action of a button in component B.
    Regards
    Sankar

    Hi,
      DATA lo_cmp_usage TYPE REF TO if_wd_component_usage.
      lo_cmp_usage =   wd_this->wd_cpuse_method( ).
      IF lo_cmp_usage->has_active_component( ) IS INITIAL.
        lo_cmp_usage->create_component( ).
      ENDIF.
    DATA lo_interfacecontroller TYPE REF TO yiwci_sg_method .
    lo_interfacecontroller =   wd_this->wd_cpifc_method( ).
      lo_interfacecontroller->execute_method(
           i was able to do the above process successfully but how to bind data to the node of component 2.
    In the component 1 : method A i defiend to get records upto 25 rows. now i tried using same method . but how to bind data using this method
    Regards
    sankar

  • How to call methode on remot computer

    I have 2 Applcations on 2 computers in Network
    App 1 on PC1 send xml file to App2 on PC2
    how to call Methods in App2 on PC2 to read the file
    // clss A on PC1
    class A
    sendFile(){
    // clss B on PC2
    class A
    readFile(){
    how to cal method readFile from Class A on PC1

    By using Remote Method Invocation, the topic of this forum.
    See the Javadoc and the RMI tutorials.

  • Calling Method in eCATT

    Hi Gurus,
    I am using eCATT in 4.7 version. I dont see the CALLSTATIC or CALLMETHOD commands in the command interface. So could you please let me know how we can call a static method in eCATT and how do we enter i/p parameters for that call.
    Thanks,
    GS.

    Hello guys,
    Figured out how to call a method in inline ABAP. Thanks for viewing my post...
    regards,
    GS
    Edited by: Get Started on Mar 24, 2009 11:15 PM
    Edited by: Get Started on Mar 24, 2009 11:15 PM

  • How to call method in web dynpro for ABAP

    Hi All,
    I created a z class and two methods to get the data.
    I created a WE4A application. Now i want to call these methods from my Z calss in the web dynpro ,but i am getting  amessage saying 'type zclass is unknown".
    when i am trying to declare
    data: cl_class type ref to zclass . i am getting above message.
    can anyone explain how to call zcalss methods in my application.

    Hi,
    You can call any global class method in WDA via. Wizard.
    Even more you can make your class as assistance class and call their methods by wd_assist.
    Thanks
    Pradeep

  • How to call methods from within run()

    Seems like this must be a common question, but I cannot for the life of me, find the appropriate topic. So apologies ahead of time if this is a repeat.
    I have code like the following:
    public class MainClass implements Runnable {
    public static void main(String args[]) {
    Thread t = new Thread(new MainClass());
    t.start();
    public void run() {
    if (condition)
    doSomethingIntensive();
    else
    doSomethingElseIntensive();
    System.out.println("I want this to print ONLY AFTER the method call finishes, but I'm printed before either 'Intensive' method call completes.");
    private void doSomethingIntensive() {
    System.out.println("I'm never printed because run() ends before execution gets here.");
    return;
    private void doSomethingElseIntensive() {
    System.out.println("I'm never printed because run() ends before execution gets here.");
    return;
    }Question: how do you call methods from within run() and still have it be sequential execution? It seems that a method call within run() creates a new thread just for the method. BUT, this isn't true, because the Thread.currentThread().getName() names are the same instead run() and the "intensive" methods. So, it's not like I can pause one until the method completes because they're the same thread! (I've tried this.)
    So, moral of the story, is there no breaking down a thread's execution into methods? Does all your thread code have to be within the run() method, even if it's 1000 lines? Seems like this wouldn't be the case, but can't get it to work otherwise.
    Thanks all!!!

    I (think I) understand the basics.. what I'm confused
    about is whether the methods are synced on the class
    type or a class instance?The short answer is; the instance for non-static methods, and the class for static methods, although it would be more accurate to say against the instance of the Class for static methods.
    The locking associated with the "sychronized" keyword is all based around an entity called a "monitor". Whenever a thread wants to enter a synchronized method or block, if it doesn't already "own" the monitor, it will try to take it. If the monitor is owned by another thread, then the current thread will block until the other thread releases the monitor. Once the synchronized block is complete, the monitor is released by the thread that owns it.
    So your question boils down to; where does this monitor come from? Every instance of every Object has a monitor associated with it, and any synchronized method or synchonized block is going to take the monitor associated with the instance. The following:
      synchronized void myMethod() {...is equivalent to:
      void myMethod() {
        synchronized(this) {
      ...Keep in mind, though, that every Class has an instance too. You can call "this.getClass()" to get that instance, or you can get the instance for a specific class, say String, with "String.class". Whenever you declare a static method as synchronized, or put a synchronized block inside a static method, the monitor taken will be the one associated with the instance of the class in which the method was declared. In other words this:
      public class Foo {
        synchronized static void myMethod() {...is equivalent to:
      public class Foo{
        static void myMethod() {
          synchronized(Foo.class) {...The problem here is that the instance of the Foo class is being locked. If we declare a subclass of Foo, and then declare a synchronized static method in the subclass, it will lock on the subclass and not on Foo. This is OK, but you have to be aware of it. If you try to declare a static resource of some sort inside Foo, it's best to make it private instead of protected, because subclasses can't really lock on the parent class (well, at least, not without doing something ugly like "synchronized(Foo.class)", which isn't terribly maintainable).
    Doing something like "synchronized(this.getClass())" is a really bad idea. Each subclass is going to take a different monitor, so you can have as many threads in your synchronized block as you have subclasses, and I can't think of a time I'd want that.
    There's also another, equivalent aproach you can take, if this makes more sense to you:
      static final Object lock = new Object();
      void myMethod() {
        synchronized(lock) {
          // Stuff in here is synchronized against the lock's monitor
      }This will take the monitor of the instance referenced by "lock". Since lock is a static variable, only one thread at a time will be able to get into myMethod(), even if the threads are calling into different instances.

  • How to call methods at selection screen?

    Hi all,
    I am developing a program in object oriented abap.
    i have defined a class and implementated, and we have to instantiate the class in start of selection.
    now the problem is how to call a method at selection screen event.
    i want to validate the inputs entered by users. so can i create a static method which can be called without instantiating a class?
    please guide me
    thanks

    Hello Mr A,
    Define the method as a Static Method and that will solve your problem. Static methods can be called directly and does not need the class to be instantiated before it can be called.
    Data: my_class type ref to zcl_report_utilities.
    At Selection-Screen.
    Call Method zcl_report_utilities=>check_selections
           exporting
              iv_repnm    = sy-cprog
            importing
              et_messages = lt_msgs.
    Start-Of-Selection.
      Create Object my_class
             exporting
                im_pernr  = ls_e1plogi-objid
                im_begda = c_lowdate
                im_endda = c_hidate.
       Call Method my_class->read_infotypes
              exporting
                 im_infty = c_org_assn
              changing
                 et_infty  = it_infty.
    Here you can see how the method check_selections is called before the class zcl_report_utilities is instantiated. The best part about the Static Methods is if you are writing the class in the Class Library (SE24), any other programs can call them directly (if they need to) without needing to instantiating the entire class before the call.
    Also note the difference in syntax when calling the static method check_selections to when calling the Instance method read_infotypes.
    Hope this solves your issue and please do not forget to reward points.
    Cheers,
    Sougata.
    p.s. if you are defining your class locally (program specific) then use Class-Methods to define a static method.
    Edited by: Sougata Chatterjee on May 1, 2008 9:53 AM

  • How to call methods from string names?

    On my java project i have a front controller. All the requests will first go to controller and i will make parameter validation on the controller level. If validation is completely ok, page will be dispatched to real servlet with validated parameters.
    If the request pattern is "photos" for example i will call static function and send referance of request object Validation.Photos(request); or if the pattern is "albums" function will be Validation.Albums(request).
    everything is ready on my codes except how to call a Validation function with a string name. Need a clear and a fast way because on every request i will do this.
    Thank you

    ahh life is problem;) another one i couldnt understand.
    import javax.servlet.http.HttpServletRequest;
    interface Validasyon {
            boolean invoke(HttpServletRequest request,String param);
         class IntIsNumeric implements Validasyon {
           public boolean invoke(HttpServletRequest request,String param) {
                param=request.getParameter(param);
                System.out.println("param="+param);
                try
                     Integer.parseInt(param);
                catch(NumberFormatException e)
                     return false;
                catch(NullPointerException e)
                     return false;
                int gelen1=Integer.parseInt(param);
                if(gelen1<1 || gelen1>Integer.MAX_VALUE)
                     return false;
                return true;
         }i am sending parameter to IntIsNumeric classes's invoke method like below
    Validasyon c=new IntIsNumeric();
    boolean a=c.invoke(request,"photo_id");but IntIsNumeric method does not recognize my input parameters "request" and "param" always return null. Why?

  • How to call method add_column in cl_salv_columns

    Hi ,
            I am devloping one salv report. I am try to call the add_column method , its showing "Access to protected method "ADD_COLUMN" is not allowed".
    But public methods are working fine.
    Please tell me how to call he Protected method .
    Thanks and Regards,
    Vaigunda Raja.

    Hi Giri,
    Thanks for your response.
    Please give the suggestion to me...
    This is my code.
    data: it_vbak type standard table of zfinal with header line,
            obj_alv type ref to cl_salv_table,
            obj_cols type ref to cl_salv_columns,
           a type sap_bool ,
            FNAME TYPE LVC_FNAME .
      select * from vbak into corresponding fields of table it_vbak up to 10 rows .
    call method cl_salv_table=>factory
       importing
         r_salv_table = obj_alv
       changing
         t_table      = it_vbak[].
      perform column_alv.
    perform display.
    form column_alv .
       obj_cols = obj_alv->get_columns( ) .
       call method obj_cols->apply_ddic_structure
         exporting
           name = 'ZFINAL'.
       call method obj_cols->is_optimized
         receiving
           value = a.
       if a ne 'X'.
         call method obj_cols->set_optimize
           exporting
             value = 'X'.
       endif.
    FNAME = 'CHECK'.
      call method obj_cols->add_column
        exporting
          columnname = FNAME
          position   = 1  .
    endform.                    " COLUMN_ALV
    form display.
       call method obj_alv->display .
    endform .                    "display
    "Error Message: Access to protected method "ADD_COLUMN" is not allowed."

  • How to call method in JCD - which will execute prepared statement

    Hi All,
    I have a scenari where I have to call method in JCD, where in this method I have to execute prepared statement and return value.
    Please suggest me how to do this.
    Thanks & Regards,
    Anitha.B

    hi bolla,
    this is 100% java code. can you elaborate a little more what is your exact problem?
    i think your scenario is easy to accomlish.
    regards chris

  • Syntax for how to call method of one comp in other comp     wd java.

    Let us assume,
    there is method1 in view1 comp1.
    tell me syntax for calling method 1 in view2 comp2
    thanks in advance.
    Edited by: madhu1011 on Nov 9, 2011 11:31 AM

    Hi Madhu,
    This is the situation:
    comp1-> method 1 , view1
    comp2-> view2
    You need to access method1  in view2 of comp2.
    For that, do the following steps:
    1.) First create a method (for eg: method1) in comp1 (under implementation of view1).
            eg: public void method1(){
                    <......some logic...>
    2.)Save the meta data.
    3.) In comp2, you will find an option called used components. In that right click and add the component comp2. (Carefully select comp1 itslef).
    4.)Save the meta data.
    5.) Then go to view2 of comp2 and take implementaion part and right the following logic in wddoinit() (or any other standard or custom method).
    wdThis.wdGetComp2Interface().getMethod("method1"); 
    By this way, we can access the method1 of comp1 in comp2.
    Regards,
    Jithin

  • How to Call Methods of one component into another Component

    Hi Experts,
    I have one requirement...
    I have 2 components A and B, i used A comp in B, i need to call Comp A methods in Component B, can anybody give me the syntax?? please...
    Thanks and Regards,
    Kissna.

    Hi Manas Thanks for your fast reply,
    My question is, for example we have wd_comp_controller or wd_this objects to call methods of view from view and comp controller right.. like this we have any methods to call used component methods? if yes can u please give me the objects syntax?...
    Thanks and regards,
    Kissna.

  • How to call method excel subtotal in ABAP program

    I'm trying to call excel method subtotal, but i get an error (sy-subrc <> 0). How to correctly call this method? One of the parameters is an array. I've tried to use an internal table as the array, but ABAP syntax checker shows error.

    Hi Vytautas,
    The best way is to start recording a Macro(Tools->Macro->Record New Macro), and then do the operations (like entering data into cells, summing up, calculations,etc...)
    once you are done, display the macro and you will find all the needful information regarding what metohds are to be called and how...
    Regards,
    Raj

  • 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.

  • How to call methods defined in another class ? is it possible?

    Hi all,
    I am new to using JNI, was wondering if this is possible and how I might be able to do this. I'm trying to call some set/get functions defined in a class that is not part of the class where I have my native code defined and called...
    Let me explain a bit, I have a class JobElement (singular Job) that stores all the data associated with a Job, such as job name, job id, etc.
    Another class JobsElement (plural Jobs) contains all the Jobs that are currently running.
    The code is set up something like this...
    class JobElement {
         String jobID;
         String jobName;
         public void setJobId(String newJobID) { jobID = newJobID; }
         public void setJobName(String newJobName) { jobName = newJobName; }
    class JobsElement {
         Date timeDateStamp;
         JobElement job;
    class AppRoot {
         JobsElement allJobs = null;
         JobElement _currentJob = null;
         public native getAllJobs();
    }In my native method, getAllJobs(), I essentially want to call the set functions that are defined for JobElement when filling in the information of the Job. (then finally add the JobElement to the JobsElement list)
    In summary, I basically want to know if it's possible to call the equivilent of this java code from the native code??
         _currentJob.setJobName(newJob)
    In the native code I tried to find the setJobID method but got a NoSuchMethodError. (which is what I expected)
    Thanks in advance.

    Hi,
    In your getAllJobs(), the JNI Equiv would be JNIEnv_ClassName_getAllJobs(JNIEnv** anEnv, jobject jAppRootobj)
    Since you are calling the AppRoot object's method, the jobj in the native method call will be jAppRootobj-AppRoot's instance.
    What you can do is
    Get the field id of _currentJob.
    Get the <jobject-value of currentJob> of JobElement i.e. currentJob.
    Then get the method ids of setJobID and setJobName.
    Call these non-static methods on <jobject-value of _currentJob> to set the values.
    I hope I made a try to help you. Please correct me if I am wrong.

Maybe you are looking for

  • Connection reset error while calling web service deployed on tomcat

    Hello Friends, I am trying to invoke a web service from web dynpro application. The web service is deployed on tomcat 5.5 server. I am creating an adaptive web service model using wsdl file. The model gets created without any error. But when applicat

  • PDF to Excel - Save As File Type - No Options

    When I am attempting to save my converted file, I do not get any options to save it as a file type...literally "Save As Type" is blank and there are no options to choose anything. So if I save it without that to my desktop, it then won't open to anyt

  • ISE Sending Hostname in CWA Redirect

    Dear Support Team. we have setup in which wireless controllers are deployed in Foreign & Anchor Scenario. (Guest WLC or Anchor is deployed in DMZ) , Controllers are running 7.3 and CWA config is done as per standard TAC documents. When WLC redirects

  • ITunes 32 bit or 64 bit?

    Greetings, I have windows 7 64 bit and have iTunes 9.2 32 bit installed, I woulkd like to use the 64 bit version of iTunes 9.2, my question is, can install the 64 bit version over the top of the 32 bit version, or is a separate 64 bit version install

  • WLC WLAN SSID L3 Security Passthru

    With passthru security the end user get a pop-up warning about accepting the self signed certifcate from the virtual ip 1.1.1.3. Is there a way to replace the certificate with a trusted public certificate?