RFC using global class.

Hello Folks,
I have developed FM using global class(se24), just calling method inside FM. My question is that, which has more prefrence a class or PERFORM.
Thanks,
Amol.

Your question is unclear. However, you seem to be saying you have created an RFC enabled function module in which you use a class. If this is the case, you've done the right thing as in later releases of ABAP performs are marked as obsolete. Further, if all your logic is inside the class, then you've the opportunity to exploit the benefits of OO over procedural programming.

Similar Messages

  • How to use global classes and display returned data?

    Hello experts,
    I have the following code in a program which accesses a global class (found in the class library). It executes one it's static methods. What I would like to do is to get hold of some elements of the returned data. How do I do that please?
    Your help is greatly appreciated.
    ***Use global class CL_ISU_CUSTOMER_CONTACT
    DATA: o_ref TYPE REF TO CL_ISU_CUSTOMER_CONTACT.
    DATA: dref_tab LIKE TABLE OF O_ref.
    DATA: begin OF o_ref2,
    CONTACTID               TYPE CT_CONTACT,
    P_INSTANCES             TYPE string,
    P_CONTEXT               TYPE CT_BPCCONF,
    P_CONTROL               TYPE ISU_OBJECT_CONTROL_DATA,
    P_DATA                  TYPE BCONTD,         "<<<=== THIS IS A STRUCTURE CONTAINING OTHER DATA ELEMENTS
    P_NOTICE                TYPE EENOT_NOTICE_AUTO,
    P_OBJECTS               TYPE BAPIBCONTACT_OBJECT_TAB,
    P_OBJECTS_WITH_ROLES    TYPE BAPIBCONTACT_OBJROLE_TAB,
    end of o_ref2.
    TRY.
        CALL METHOD CL_ISU_CUSTOMER_CONTACT=>SELECT  "<<<=== STATIC METHODE & PUBLIC VISIBILITY
          EXPORTING
           X_CONTACTID = '000001114875'   "Whatever value here
          RECEIVING
            Y_CONTACTLOG = o_ref
    ENDTRY.
    WHAT I WOULD LIKE TO DO IS TO MOVE o_ref TO o_ref2 and then display:
    1) P_DATA-PARTNER
    2) P_DATA-ALTPARTNER
    How can I do this please?

    I now have the following code. But when I check for syntax I get different error. They are at the end of the list.
    Here is the code the way it stands now:
    ================================================
    ***Use global class CL_ISU_CUSTOMER_CONTACT
    DATA: oref TYPE REF TO CL_ISU_CUSTOMER_CONTACT.
    DATA: dref_tab LIKE TABLE OF oref.
    DATA: begin OF oref2,
    CONTACTID TYPE CT_CONTACT,
    P_INSTANCES TYPE string,
    P_CONTEXT TYPE CT_BPCCONF,
    P_CONTROL TYPE ISU_OBJECT_CONTROL_DATA,
    P_DATA TYPE BCONTD,      "THIS IS A STRUCTURE CONTAINING OTHER DATA ELEMENTS
    P_NOTICE TYPE EENOT_NOTICE_AUTO,
    P_OBJECTS TYPE BAPIBCONTACT_OBJECT_TAB,
    P_OBJECTS_WITH_ROLES TYPE BAPIBCONTACT_OBJROLE_TAB,
    end of oref2.
    TRY.
    CALL METHOD CL_ISU_CUSTOMER_CONTACT=>SELECT     " STATIC METHODE & PUBLIC VISIBILITY
    EXPORTING
    X_CONTACTID = '000001114875' "Whatever value here
    RECEIVING
    Y_CONTACTLOG = oref
    ENDTRY.
    field-symbols: <FS1>      type any table,
                   <wa_oref2> type any.
    create data dref_tab type handle oref.   " <<===ERROR LINE
    assign dref->* to <FS1>.
    Loop at <FS1> assigning  <wa_oref2>.
    *use <wa_orfe2> to transfer into oref2.
    endloop.
    write: / 'hello'.
    =========================================
    Here are the errors I get:
    The field "DREF" is unknown, but there is a field with the similar name "OREF" . . . .
    When I replace itr by OREF I get:
    "OREF" is not a data reference variable.
    I then try to change it to dref_tab. I get:
    "DREF_TAB" is not a data reference variable.
    Any idea? By the way, must there be a HANDLE event for this to work?
    Thanks for your help.

  • Is it possible to use Global class variable in a  BAdi

    Hello Experts,
      I have a requirement wherein ,
             I need the Reference of the Class Object to be used in a BAdi. The class object is defined as a global variable.
    By any means can I use the reference variable inside the BAdi.
    thanks

    Hi Hari,
    U can access any objects or variables in BADI only if they are used as parameters in it.
    So please check whether that global object is declared as parameters in the corresponding BADI.
    If so, you can surely use it.
    Reward points if this is useful.
    Regards,
    kamalapriya

  • Global classes / Doppelclick

    Hello Every Body,
    please can someone tell me how can implement Doppelclick using Global classes.!!
    Best regards.
    daniel

    Hello Daniel
    I assume you want to handle DOUBLE_CLICK events of controls (e.g. ALV grid, tree) using global classes.
    That's a piece of cake. Below I outline a possible procedure:
    (1) Create your control instance (e.g. go_grid, CL_GUI_ALV_GRID)
    (2) Create an instance of your global class. The CONSTRUCTOR method may look like this:
    CREATE OBJECT go_myclass
      EXPORTING
        io_instance = go_grid.  " Assumption: class should only handle ALV grid events
    METHOD constructor.
      me->mo_grid = io_instance.  " class may have instance attribute for grid instance
      me->set_handler( ).  " perhaps private method for setting event handler 
    ENDMETHOD.
    METHOD set_handler.
      SET HANDLER: handle_double_click FOR me->mo_grid.
    ENDMETHOD.
    (3) Create an event handler method (e.g. HANDLE_DOUBLE_CLICK for event DOUBLE_CLICK of cl_gui_alv_grid) within your global class.
    That's it. As soon as the user double-clicks on a row in the ALV grid (go_grid) the method HANDLE_DOUBLE_CLICK of your global class will be called to handle the event.
    Regards
      Uwe

  • Creation of Material using BDC Session method & global class

    Hi
    Creation of Material using BDC Session method & global class by using oops.
    can anyone plz help me out

    Hi,
    it looks like it's not possible to call this BAPI wihtout material number. Here is a quote from BAPI documentation.
    When creating material master data, you must transfer the material
    number, the material type, and the industry sector to the method. You
    must also enter a material description and its language.
    Cheers

  • Major global classes used in abap objects

    Hi,
    I am new to the abap objects and till now i am to understand that the role of the global classes are important in the abap object program. I had tried to search on the net but i was not able to get the desired result.
    I want to know which are the major global classes which are used in the ABAP objects.
    Plzz provide me guidelines for it.

    Ricx,
       It depends on your requirement.
    For alv's we use these global classes. For Webdynpro related alv we use different global classes.
    CL_GUI_ALV_GRID (List Viewer)
    CL_GUI_ALV_GRID_BASE (Basis Class for ALV grid)
    CL_GUI_ALV_TREE (ALV Tree Control)
    CL_GUI_ALV_TREE_SIMPLE (Simple ALV Tree)
    CL_ALV_TABLE_CREATE (Dynamic Creation of ALV Data Table)
    CL_ALV_TREE_BASE (Basis Class ALV Tree Control)
    CL_CK_ALVTREE_NKEY_2_OBJECT (Converter Node Key Object)
    CL_ALV_EVENT_DATA (Changing Data Container for Events)
    CL_ALV_EVENT_TOOLBAR_SET (ALV Context menu)
    Regards,
    Arun.

  • Can we use SAMT to syntax check methods in global classes ?

    Transaction SAMT can be used to perform syntax checks on programs but I can't see how to use it to check methods in global  classes. Can anyone tell me how to do this ?
    thanks,
    Malcolm.

    I've figured out a way to do this.
    You need to put the class name followed by '=====CP' into the program name......with enough ='s to make the name up to 32 characters. Bit fiddly but it can be done.

  • How to use abap memory in global class

    Hi experts,
                     I want to  know how to use abap memory in global class. when i try write export and import statement its showing
    error is export statement does not support in object oriented concept.
    Thanks
    Ramesh Manoharan

    Hi Ramesh,
    Export and import statements were not allowed to use in  classes. Create a global variable in public section of that class of type of  export parameter.Then pass value to the global variable of class  by calling that class.
    by
    Prasad GVK.

  • Using container from another global class

    There are two global classes being used by me in a program - Class A and Class B.
      Class A contains the container to display ALV.
      Class B contains the logic to display ALV.
      class B is used as attribute class in Class A.
      How is that I can use the container from Class A from class B?

    Like this?
    class A ...
       public section.
          methods: get_container returining value(ref_cont) type ref to ...,
                          constructor.
       private section.
          data ref_container type ref to....
    endclass.
    class A impl...
       method get_container.
            ref_cont = me->ref_container.
       endmethod.
       method constructor.
          create object ref_container ....
       endmethod.
    endclass.
    class B ...
       public section.
           methods: constructor,
                          display alv.
       private section.
           data ref_alv type ref to....
           data ref_A type ref to A.
    endclass.
    class B impl...
       method constructor.
           data lr_container type ref to ...
           if ref_A is not bound.
                create object ref_A.
          endif.
          "get container from class A
           lr_container = ref_A->get_container( ).
           create object ref_alv
                exporting
                     container = lr_container
       endmethod.
       method display_alv.
            call method ref_alv->set_table_for_first_display...
        endmethod.
    endclass.
    If storing container's reference under local LR_CONTAINER in class B constructor causes not displaying ALV, you will have to store this under class B attribute. Alternative would be directly indicating the container reference as parent to ALV by calling functional method like
    create object ref_alv
          exporting
               container = ref_A->get_container( )    
    this will however work in recent releases of SAP NW AS.
    Regards
    Marcin

  • Create Global Class Definition using Local Class Source Code

    I would like to be able to automate the creation of global class definitions using source code that is defined in a text file (one example: convert a local class def to a global class def).
    Does SAP deliver this functionality?  (I'm already aware of the various classes that can be used to create global classes and how those classes can be implemented in a program to generate new classes.  I'm hoping to avoid having to create a custom solution.)
    Thanks in advance!

    We have a winner!
    Thanks Rich!
    It's not a 100% solution - I was hoping to be able to generate global classes/interfaces using source code alone, without requiring user intervention.
    It <i>is</i> however, a 90-95% solution because debugging SE24 reveals that by using a combination of the FM's SCAN_ABAP_OBJECTS_CLASSES & SEO_CLIF_MULTI_IMPORT, I should be able to <u>quickly</u> put together that custom application that I was trying to avoid.
    I knew about the existance of SEO_CLIF_MULTI_IMPORT but I did not know about SCAN_ABAP_OBJECTS_CLASSES.  I'm very happy to learn that I'm not going to have to write a parser!

  • Use of classes Vs tables

    Hi All,
    I have e requirement where i need to select data from tables....... It was told to me that i can make use of classes instead of tables...... I am working on Inbound delivery in EWMmodule.......
    can any one through some light on this....... how can i make use of classes to get data from sap tables.........
    Regards,
    Poonam

    Hi Faisal,
    Just to correct you it's "Methods of Global Persistent Classes".
    Not to hide my ignorance in OOPs, but i don't think persistent classes should be used for mundane selects. It's much easier to write, maintain & troubleshoot a select construct than a persistent class
    You can go through this discussion on: Why do we need Persistent Classes ?
    BR,
    Suhas

  • Needs help.....Please about using different classes

    I don't know how to use differenet classes.
    Please tell me how to write class to suit Start. This stuff me up. Please .... help me
    <<My program>>
    //Start
    public class Start
    {  private Artist[] Artists;
    private Record[] records;
    private Person[] Manager;
    private TextMenu makeMenu = new TextMenu();
    public static void main(String[] args)
         Start studio = new Start();
    studio.menu();
    public Start()
    {  //Person.Manager(ManagerName,HouseNumber,StreetNumber,PhoneNumber)
         Manager = new Person[1];
         Manager[0] = new Person("Yangfan",88,"Young ST",11118888);
         //Artist(GroupID,ArtistName,HouseNumber,StreetNumber,PhoneNumber)
         Artists = new Artist[5];
    Artists[0] = new Artist(1,"Backstreet Boys",58,"Music ST",99998888);
    Artists[1] = new Artist(2,"Santana",68,"Music ST",99998899);
    Artists[2] = new Artist(3,"Macy Gray",78,"Music ST",55558888);
    Artists[3] = new Artist(4,"Ricky Martin",88,"Music AVE",77778888);
    Artists[4] = new Artist(5,"Did Rock",55,"Music Road",66667777);
    //Record(RecordingID,RecordName,Artist,StartTime,FinishTime,RecordingDate,GuestArtist1,GuestArtist2)
    records = new Record[6];
    records[0] = new Record(1,"I want it that way",Artists[0],11,12,"05/08/2001",Artists[1],Artists[3]);
    records[1] = new Record(2,"Smooth",Artists[1],11,12,"05/08/2001",Artists[1],"");
    records[2] = new Record(3,"Do something",Artists[2],11,"05/08/2001",Artists[3],"");
    records[3] = new Record(4,"Livin La Vida Loca",Artists[3],11,12,"05/08/2001",Artists[1],Artists[3]);
    records[4] = new Record(5,"Bawitdaba",Artists[4],11,13,"05/08/2001",Artists[1],"");
    records[5] = new Record(6,"The one",Artists[0],11,14,"05/08/2001",Artists[1],"");
    public void menu()
    {  String[] choices = {">>>List Manager Details",">>>List All Artist Names",">>>List An Artist Telephone-Number",">>>Show Details For One Recording",">>>Add A New Recording",">>>List The Recording Costs For All Artists",">>>List Artist's Reocording",">>>Exit Program"};
    while (true)
    {  switch (makeMenu.getChoice(choices))
    {  case 1: showAllArtists();
    break;
    case 2: showAllRecords();
    break;
    case 3: System.exit(0);
    break;
    case 4: System.exit(0);
    break;
    case 5: System.exit(0);
    break;
    case 6: System.exit(0);
    break;
    case 7: System.exit(0);
    break;
    case 8: System.exit(0);
    break;
    default:
    public void showAllArtists()
    {  int numArtists = Artists.length;
    for(int i = 0; i < numArtists; i++)
    {  Artists[i].displayArtistDetails();
    public void showAllRecords()
    {  for (int i = 0; i < records.length; i++)
    {  System.out.println();
    records.printRecordDetails();
    <<Assignment>>
    Due - midnight, Wednesday August 22nd
    This assignment will test your knowledge of Java programming using classes, encapsulation and javadoc.
    The base requirements
    Write a complete Java class to manage a Digital Recording Studio. The studio wants to keep a list of all Artists that use the studio and also wishes to keep track of all Recordings that have been made. An important function of the program is to calculate the time spent making a recording and charge the Artist for the time used.
    You must create at least the following classes, Start, Studio, Person, Artist, Recording, Address. You may create other classes if needed as well
    Start will contain main(), create one instance of a Studio and execute a Menu of commands to test your code. Studio should contain a studio name, an array of Artist and an array of Recording plus the studio manager (a Person). Each Artist should contain the name of the group and an Address. Each Person will have a name and a home address. Each recording will have a Title (usually song title), an Artist (only one), and a list of guestArtist (they are Artist�s but will not receive royalties) the number of the CD the recording is stored on (numbers are numerical and recordings are saved on CD-R), plus the recording start and finish times for the recording session (suggest you use Java Date class � refer to the API). An Address will contain, house number (integers only), a street name and a telephone number. There is no need to store city and country.
    To enter a set of data for testing your program � main() should call a method in the Start class that will fill in a set of values by creating objects and filling in values by calling methods in each class. This is the ONLY method allowed to be longer than 1 page long � normally we would read the data from a file but there are no O-O principles that can be learnt with simply filling in data values. It is suggested to create say at least 4 Artist�s and 6 Recordings (at least one with 1 guest Artist and one with 2 guestArtist�s)
    A menu for testing your program should be provided (it is suggested to put the Menu into a separate class as you need at least 3 menus). While other commands are possible, only the following ones will receive marks.
    Menu commands needed are
    List the Managers name, address and telephone number
    List all Artist Names
    List an Artist telephone number (a sub menu showing valid Artist�s is required)
    Show all details for one Recording ( sub menu of valid Recordings will be needed and remember there can be more than one guestArtist)
    Add a new Recording, user will need to be prompted for all details.
    List the recording costs for all Artists � show each Artist on a separate line with their name and total amount, charge for using the studio is $1000 per hour or part thereof, example for a 1 hour and 10 minute recording the Artist will be billed for 2 hours.
    List all the Recording�s one Artist has worked on (sub menu of Artists needed), the list should show whether they were the Artist or a guestArtist
    Exit program
    Use fixed sizes for arrays, suggest 20 is suitable for all arrays. Java can handle dynamic data structures (where the number of elements can grow or shrink), but that is beyond a first assignment.
    Do NOT make ANY methods static - this defeats the Object Oriented approach and will result in ZERO marks for the entire assignment.
    Data MUST be encapsulated, this means that all the data relating to an object are to be stored INSIDE an object. None of the data detail is to be globally available within your program - hence do not store Artist names in either Studio or Recordings � just store a reference instead. Do NOT create ID numbers for Artists, you should use References instead � for many students this will be the hardest part as you have to use Objects, not program in a C style to solve the problem. Note that if there are any non-private data in classes then zero will given for marks for encapsulation.
    Good programming style is expected (see web page or lecture notes). In particular, you must use javadoc to generate a set of html pages for your classes. Make sure you use the special javadoc style comments in your source code. Marks will be granted for both using javadoc and also for including sensible javadoc comments on each class and each public method.
    What to Hand In
    Read the turnin page, basically the .java files, a readme.txt to tell the marker which file the program starts from plus the javadoc (html) files. Do NOT send .class files (if you do send these we will delete them and recompile your program), do NOT compress with gtar, tar, zip or use any other tool on your files. Turnin automatically compresses all your files into a single archive for us to mark.
    The simplest way to turnin all your files is to place all files in one directory then just use the *.* wildcard to turn in all files within that one directory.
    You must turnin all files that are not part of Java 1.3. In particular, you are allowed (actually encouraged) to use EasyIn or SavitchIn but should include the one you use in the files you submit. It is STRONGLY suggested that you copy all the files into another directory, test it works there by compiling and executing then turnin files from that directory. A common problem is students adding comments at the last minute then not testing if it still compiles. The assignment will be marked as submitted � no asking later for leniency because you added comments at the last minute and failed to check if it still worked.
    If the tutors are unable to compile your submission, they will mark the source code but you will lose all the execution marks. Sorry, but it is your responsibility to test then hand in all files.
    Comments
    For CS807 students, this program should be fairly easy if it was to be programmed in C (you would use several struct). The real art here is to change over to programming objects. Data is contained in an object and is not global. This idea is essential to using Java effectively and is termed encapsulation. Instead of using function(data), you use objectName.method( ). Effectively you switch the data and functions around, the data has a method (function) attached to it, not the other way around as in C (where you have a function and send data to it).
    While there will be some marks for execution, the majority of the marks will be given for how well you write your code (including comments and documentation) and for how well you used O-O principles. Programs written in a C style with most of the code in one class or using static will receive ZERO marks regardless of how well they work.
    You are responsible for checking your turnin by reading the messages turnin responds with. Failure to read these messages will not be an acceptable excuse for submitting an incorrect assignment. About 2% of assignments sent to turnin are unreadable (usually empty) and obtain 0.
    Late submissions
    Late submissions will only be accepted with valid reasons for being late. All requests for assignment extensions must be made via email to the lecturer. Replies for acceptance or refusal will made by email. Instant replies are unrealistic (there is usually a flood of queries into my mail box around assignment due dates) and the best advice is to ask at least 4 days in advance so that you will have a reasonable chance of getting a timely reply and allow yourself enough time to submit something on time if the extension is not granted.
    ALL late submissions will be marked LAST and will NOT be sent to tutors for marking until all other assignments have been marked. As an example, if you submit late and your assignment is not yet marked by the time assignment 2 is due then it will be pushed to the end of the marking pile as the assignments that were submitted on time for assignment 2 will take priority.
    If you make a second submission after the submission date, only the first submission will be marked. We will not mark assignments twice! You can update your submission BEFORE the submission date if you need to - this will just overwrite the first submission. The latest time for a late submission is 5pm on the Wednesday after the due date. This is because, either a solution will be handed out at that lecture or details of the assignment will be discussed at the lecture. I cannot accept any assignment submissions after that time for any reason at all including medical or other valid reasons. For those who are given permission to be later than the maximum submission time � a different assignment will be handed out. Remember, if you decide to submit late you are VERY UNLIKELY to receive feedback on your assignments during semester.
    Assignments will be removed from turnin and archived elsewhere then forwarded to tutors for marking on the morning after the assignment is due. A different tutor will mark each of your assignments � do not expect the tutor you see at the tutorials to be your marker.
    Marks will be returned via email to your computer science yallara account � ideally within 2 weeks. I will send marks out when I receive them so do not send email asking where your marks are just because a friend has theirs. If you want your email forwarded to an external account, then place a valid .forward file into your yallara account. The Help Desk on level 10 can assist you in setting this up if you do not know how to do it.

    I have seen other people who have blatantly asked for
    other people to do their homework for them, but you
    are the first person I've seen to actually cut and
    paste the entire assignment as it was handed to you.
    Amazing.
    Well, unlike some of the people you're talking about, it seems like zyangfan did at least take a stab at it himself, and does have a question that is somewhat more sepcific that "please do this homework for me."
    Zyangfan,
    marendoj is right, though. Posting the entire assignment is kind of tacky. If you want to post some of it to show us what you're trying to do, please trim it down to the essential points. We don't need to see all the instructor's policies and such.
    Anyway, let me see if I understand what you're asking. You said that you know how to write the code, but only by putting it all in one class, is that right? What part about using separate classes do you not understand? Do you not know how to make code in one class aware that the other class exists? Do you not know how code in class A can call a method in class B?
    Please be a bit more specifice about what you don't understand. And at least try using multiple classes, then when you can't figure out why something doesn't work, explain what you did, and what you think should have happened, and what did happen instead.
    To get you started on the basics (and this should have been covered in your course), you write the code for two classes just like for one class. That is, for class A, you create a file A.java and compile it to A.class. For class B, you create a file B.java and compile it to B.class. Given how rudimentary you question is, we'll skip packages for now. Just put all your class files in the same directory, and don't declare packages in the .java files.
    To call a method in class B from code that's in class A, you'll need an object of class B. You instantiate a B, and then call its methods.
    public class B {
      int count;
      public B() { // constructor
      public void increment() {
        count++;
    public class A {
      public static void main(String args[]) {
        B b = new B();
        b.increment();
    }Is this what you were asking?

  • Error while usind Private Method of a global class

    HI All..
    I created a global class (ZLINE_GLOBAL) which has TOT_DATA private method. I have to call this private method in my report, I know that using Friend class we can do this.
    But it is not working and showing the same error  "  METHOD "TOT_DATA" is unknown or Private or Public..
    code i tried is
    CLASS c2 DEFINITION DEFERRED.
    CLASS ZLINE_GLOBAL DEFINITION FRIENDS c2.
      PUBLIC SECTION.
        METHODS : m1.
      PRIVATE SECTION.
        METHODS: m2.
    ENDCLASS.
    CLASS ZLINE_GLOBAL IMPLEMENTATION .
      METHOD m1.
        WRITE : 'Public Method C1'.
      ENDMETHOD.                    "M1
      METHOD m2.
        WRITE : 'Private Method C1'.
      ENDMETHOD.
    ENDCLASS.
    CLASS c2 DEFINITION FRIENDS ZLINE_GLOBAL.  "my friends are here, allow them access to my (C2's) private components
      PUBLIC SECTION.
        METHODS :m3.
    ENDCLASS.
    CLASS c2 IMPLEMENTATION.
      METHOD m3.
        DATA : obj TYPE REF TO ZLINE_GLOBAL.
        CREATE OBJECT obj.
        CALL METHOD obj->TOT_DATA.    "here Iam calling Private method of global class
      ENDMETHOD.                    "M3
    ENDCLASS.
    START-OF-SELECTION.
      DATA obj_c2 TYPE REF TO c2.
      CREATE OBJECT obj_c2.
      obj_c2->m3( ).
    can anybody help me on this..
    Murthy

    Hi Murthy,
    Replace TOT_DATA with M2, you do not have any method by name "TOT_DATA" in your code.
    CLASS c2 DEFINITION DEFERRED.
    CLASS ZLINE_GLOBAL DEFINITION FRIENDS c2.
      PUBLIC SECTION.
        METHODS : m1.
      PRIVATE SECTION.
        METHODS: m2.
    ENDCLASS.
    CLASS ZLINE_GLOBAL IMPLEMENTATION .
      METHOD m1.
        WRITE : 'Public Method C1'.
      ENDMETHOD.                    "M1
      METHOD m2.
        WRITE : 'Private Method C1'.
      ENDMETHOD.
    ENDCLASS.
    CLASS c2 DEFINITION FRIENDS ZLINE_GLOBAL.  "my friends are here, allow them access to my (C2's) private components
      PUBLIC SECTION.
        METHODS :m3.
    ENDCLASS.
    CLASS c2 IMPLEMENTATION.
      METHOD m3.
        DATA : obj TYPE REF TO ZLINE_GLOBAL.
        CREATE OBJECT obj.
        CALL METHOD obj->M2.    "here Iam calling Private method of global class
      ENDMETHOD.                    "M3
    ENDCLASS.
    START-OF-SELECTION.
      DATA obj_c2 TYPE REF TO c2.
      CREATE OBJECT obj_c2.
      obj_c2->m3( ).
    Regards,
    Chen

  • Export global classes to a local file

    Hi,
    is it possible to export a global class with all of its attributes, types, methods and more to a local file for archiving purposes?
    We are currently using ECC 6.0, btw.
    Michael

    Sure, via [SAPlink|http://code.google.com/p/saplink/]
    Regards
    Marcin

  • Select option in global class

    Hi,
    I want to add one data dictionary field as select option in a global class. I am trying to declare as table type. But i missed out something and it is not working. Could anybody help me out in this.
    Regards,
    Krishna.

    Hello Krishna
    You may have a look at table type RSELOPTION (line type RSDSSELOPT).
    Alternatively, you can use a trick to "import" select-options for a selection screen into your class:
    How to pass a select-options to a class method
    Passing select-options value in method
    Regards
      Uwe

Maybe you are looking for

  • Windows Vista won't let my Mac mini print

    the problem is I have a PC running Vista with a usb printer attached to it, I have printer sharing turn on the firewall is disable. A Mac Mini (PPC, 10.4.11) it connects to the network wirelessly the firewall on it is disable too, I want the mini to

  • Executing a command in the OS

    I think I got the idea now, but if my line looks as follows: Process p = Runtime.getRuntime().exec( "ls -t *.??") I get an error message that says no such file or directory. it appears the wild card characters, * or ?? , or being ignored . Any sugges

  • Form fields appear normal on my computer, but are too large on client's computer

    I recently created a fillable PDF using Acrobat Pro for a client. I have done this many times before, and never had any issues with formatting.  On my computer, the fields appear perfect, but on the client's computer they are too large and obscure th

  • Webreporting: Variable offsets

    Hi all, i have created a query with a time variable for the characteristic "calendar day"! I am using a range within an sap exit variable "actual calendar month"! To get this i restricted a key figure by selecting "range" and use this variable in res

  • Device identifier is invalid

    I am a complete newbie and am trying to use my brand new PCI-6601.  Measurement & Automation Explorer reports the name of the board as "Dev1" and the test panel application that uses "Dev1/ctr0" works properly.  However, when I compile and run the cn