Naming a method in BOR object.

I would like to know the process involved in writing a new method.
Beyond just coding ,
whats is the process involved for a new method like given below.
existing object add a new method
BOR Object :
Include <object>
BEGIN_METHOD changing container.
DATA:
submit program zxyz
END METHOD.
Thanks in advance.

Thanks for response.
I tried this way : Is it correct
edit - create
pop up :create function module as template ?
1)when do u go for function module as a template.
2)Pls describe below parameters ,when they are used.
For eg:
i see CALL FUNCTION 'Z--' in an existing method
and other case is submit program.here a screen will be the output of the report pgm which is called in the method.
3) what will be the test result of this BOR with many methods like this.
edit - create
pop up :create function module as template ?
if press no create method window appears with below details,
general - dialoue,sunchronous,result parameter,insatnce independent
result type
ABAP  dictionary
reference table
reference field
search help
object  type
Multiline
ABAP -function module,API function,transaction, dialog module ,report,other name -

Similar Messages

  • How to call BOR object- method in custom program

    hi all,
    I have the following details:
    BOR object : INSTLN
    Method: createdirect
    I need to call the above method in my custom program.
    I need to call it entirely. Means if it contains fn modules I dont want to call those fn modules seperately.

    Hi Sammy,
    Phil Soady from SAP Australia provided me with this little gem a few years back. The actual documentation for this can be found somewhere in the workflow programming area, but I just looked and couldn't find it for you. Anyway, this is a sample program I built to show how to do this. In this example I call the Display method of the Sales Document BO.
    INCLUDE <cntn02>.
    INCLUDE <cntn03>.
    FUNCTION zcallbomethod.
    *"*"Local interface:
    * Data declaration
      DATA: vbak_ref TYPE swc_object.
    * Declare and initialise container
      swc_container container.
      swc_create_container container.
    * Create object reference to sales document
      swc_create_object vbak_ref 'VBAK' '0000000009'. "Sales Document Number
    * Call Display
      swc_call_method vbak_ref 'Display' container.
    * Error handling
      IF sy-subrc NE 0.
      ENDIF.
    ENDFUNCTION.
    Cheers
    Graham Robbo

  • BOR object cannot use function module as method

    Hi All,
    I have a function module with an import parameter referring to data element DE_ABC. BOR indicates that it doesn't support this data type. However, if I define a DB table with a field whose type is DE_ABC and use that field as reference in FM interface definition, that FM can be used by the BOR object. Does anybody have any idea about this issue?
    Best Regards
    Jerome

    Hello,
    Please always mention version. It may help if you told us what data type, but to give a theoretical answer I'd say this would be correct behaviour.
    BOR is old, it was created to bring some kind of OO to then procedural ABAP. It has also not changed much, therefore doesn't support some of the newer data types. On the other hand it doesn't look at the components of a structure, so placing an unsupported element into a structure is a perfect workaround.
    Be careful however when using deep structures or one of the variable length types such as STRING. As I use classes most of the time I have no idea how they would behave but a quick test should verify whether it works.
    Hope that helps,
    Mike

  • Mthod-Call of BOR-Object

    Hi!
    I've to create objects of the BOR-Object PDOTYPE_F. There is a method named CREATE.
    Is it possible to call this method in a "normal" ABAP-Coding. Does anybody knows an example coding?
    Any hints are welcome!
    Thanks
    Peter

    Hi,
       Below is a sample code in ABAp
       Hope this may be helpful
    INCLUDE OLE2INCL.                                              
    DATA EXCEL    TYPE OLE2_OBJECT.                               
    DATA WORKBOOK TYPE OLE2_OBJECT.                               
    Regards,
    Amole                                                  
    CREATE OBJECT   EXCEL    'Excel.Application'.                 
    CALL METHOD  OF EXCEL    'Workbooks' = WORKBOOK.              
    CALL METHOD  OF WORKBOOK 'Open'    EXPORTING #1 = 'C:\EX1.XLS'.

  • BOR Objects in ABAP OO class

    Hi
              I am using a BOR objects, but in one of my activity I am trying to use a Z class. In the method of the Z class I want to get some of the attributes of the BOR class.
    I have followed the same approach ( Defining constant ) as mentioned in the blog by Jocelyn Dart.
    I am able to get the Binding in the workflow but not able to get the attribute value or instantiated object in the method.
    How do I get those attributes or the instance of the BOR object in the method. Am I missing something?
    Thanks
    Dhaval

    Hi
               Well I wanted to achieve something as follows:
    1) The workflow was getting triggered from an Event of the BOR. So the binding was from the event to the workflow
    2) Now the second step in the workflow was a method of a Zclass in the workflow. Somehow I was not getting the key of the BOR to the class so that the class can be instiated. ( Say the PR number or PO number which triggered the event)
    I am able to do it using static attribute of the class to instiate the class. I do know whether the approach is right, but somehow it resolved my issue.
    1) I declared a static attribute in the class.
    2) Defined a container and hold the value in the container from the event object id. ( This holds the PO number which triggered the workflow )
    3) In the binding between the workflow and the task where my class was used, I passed the container to the static attribute of the class.
    4) In the class method  FIND_BY_LPOR, I used the static attirbue instead of LPOR-INSTID to create the object.
    Thanks for you help.
    Regards
    Dhaval

  • Meaning of factory method in abap objects

    Hi,
    Can anybody help me in understanding the meaning of factory method in abap object? what is the importance of this?
    Regards
    Sudhansu

    Hi Krish and Sudhansu,
    Design patterns are solutions which are already verified and known by many developers. That is why it is worth to use them. There is no need to reinvent the wheel in many cases.
    I would recommend book which is placed in the ABAP world:
    http://www.sap-press.com/products/Design-Patterns-in-Object%252dOriented-ABAP-(2nd-Edition).html
    Although Java language has intuitive syntax, there are some special things in ABAP development so it is better to check solutions adjusted for ABAP editor.
    The most common usage of factory pattern is to simplify object creation.
    - By one method call you provide required parameters and do all initializations, including dependent objects.
    - Class can have many factory methods, if you want to provide more ways of initialization.
    - Factory method is usually static in the class and they return initialized instance of object for this class.
    - There is naming convention to start factory method name with "create" - easy to recognize pattern.
    - If you set property of class to "private instantiation" then you force to use factory method for object creation. In this way it is really simple to find all places where object are created with given set of input parameters - find references of factory method.
    Factory pattern becomes even more powerful if we add inheritance. Factory method returns basic object (like ZCL_VEHICLE) but its implementation can return different subclass instance, depending on input parameter (ZCL_CAR, ZCL_TRAIN etc). Each instance can implement differently behavior (methods implementation), but these are object oriented techniques.
    Regards,
    Adam

  • BOR Objects and ABAP

    Guys,
    Not even sure if this is possible...
    How do I find BOR calls in an ABAP program.
    Example: BUS2088 or BUS2008 in program SAPLCOIH - for PM/CS orders).
    PeteA

    Hi Peter,
    Specify your business object and the method of the BOR object in the BASIC data tab in PFTC transaction.
    If you want to trigger the Workflow through and event then you will have to first link your event of the Business Object to the WorkFlow Task in Workflow Builder (TCODE PFTC) and then you can do the following :
    Please refer the code below to for your information.
    Data for workflow trigger
    DATA: objtype LIKE swetypecou-objtype,
    objkey LIKE sweinstcou-objkey,
    event LIKE swetypecou-event,
    event_container LIKE swcont OCCURS 0 WITH HEADER LINE.
    objtype = 'ZBUS1001'. "Material [sub object of BUS1001]
    MOVE v_wfmatnr TO objkey. "V_WFMATNR is material number
    event = 'CreatePLMMaterial'."Custom Event defined in
    ZBUS1001 [Tcode SWO1]
    REFRESH event_container.
    *Following are the Event parameters required in the *Workflow
    swc_set_element event_container 'Attachment' v_wfattachment.
    swc_set_element event_container 'Material' v_wfmatnr.
    swc_set_element event_container 'TisGroup' v_wftisgroup.
    swc_set_element event_container 'SchDate' v_schdate.
    CALL FUNCTION 'SWE_EVENT_CREATE'
    EXPORTING
    objtype = objtype
    objkey = objkey
    event = event
    TABLES
    event_container = event_container
    EXCEPTIONS
    objtype_not_found = 1
    OTHERS = 2.
    IF sy-subrc <> 0.
    MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
    WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
    ENDIF.
    COMMIT WORK.
    Please reward some points if it helps you.
    Regards,
    Amit M. Mishra

  • Generic BOR Object - TSTC

    Hi all,
    Can anyone let me know how the generic BOR object 'TSTC' can be used to call transactions from CRM4.0(SIE) to backend R/3 systems in a transaction launcher. Basically, i will be interested in knowing
    - how one can pass the transaction code
    - any customizing settings required for this
    Regards
    Hem

    Hemchandra,
    You can launch R/3 Transactions into IC WebClient using Transaction Launcher wizrd.
    Important points to be followed
    1. ITS should be configured properly
    2. Use the Tx Launcher Wizard and select transaction  type as BOR and choose TSTS_PAR in the next screen
    and select the process type parameter from list box and enter the R/3 Tx Code as value parameter.
    3. You can see the transaction code,process type parameters in the method PREPARE_DATA_FLOW of Action Handler class
    ex:
      bdc ?=
        gv_view_controller->get_custom_controller( 'CuCoBDC' ). "#EC NOTEXT
    <b>        TRANSACTIONCODE =
      'VA01'. "#EC NOTEXT</b>
      me->set_data( iv_name = gc_TRANSACTIONCODE
                    iv_value = TRANSACTIONCODE ).
          SALESDOCUMENTTYPE =
      'OR'. "#EC NOTEXT
    Hope this helps.
    Thirumal.

  • Send Archived BOR Object as an Email Attachment

    Hi,
    I am sending an email with Attachments. There are some archived documents which are scanned and stored as pdf files.
    I need to send these  documents attached together with the email as attachment.
    *I have retrieved the BOR keys of the files to be sent. However, I am unable to physically attach these to the email. *
    I have written the following code.
    * Get attached BOR objects
      call method gr_case->bor_objects_get
        receiving
          re_bor_objects = lt_attachmnt
        exceptions
          failed         = 1
          others         = 2.
    * Build list of attachments
      loop at lt_attachmnt into ls_attachmnt.
        lv_object-describe = c_object_desc.
        lv_object-objtype  = ls_attachmnt-bor_type.
        lv_object-objkey   = ls_attachmnt-bor_key.
    *   Write Packing List (Attachments)
        ls_objpack-head_start = 1.
        ls_objpack-head_num   = 1.
        ls_objpack-body_start = 0.
        ls_objpack-body_num   = 0.
        ls_objpack-doc_type   = 'OBJ'.
        ls_objpack-obj_name   = ls_attachmnt-bor_type.
        ls_objpack-obj_descr  = ls_attachmnt-bor_key.
        append ls_objpack to lt_objpack.
      endloop.
    * send mail
      call function 'SO_NEW_DOCUMENT_ATT_SEND_API1'
        exporting
          document_data              = ls_doc_change
          put_in_outbox              = 'X'
          commit_work                = 'X'
        tables
          packing_list               = lt_objpack   " 1. row for document, following rows for each attachment
          object_header              = lt_objheader " e.g. for the filename
          contents_txt               = gt_text_tab  " content of ASCII data
          receivers                  = lt_receiver  " recipient
        exceptions
          too_many_receivers         = 1
          document_not_sent          = 2
          document_type_not_exist    = 3
          operation_no_authorization = 4
          parameter_error            = 5
          x_error                    = 6
          enqueue_error              = 7
          others                     = 8.
    This code sends some text files as attachments with the description of the BOR objects.
    Can someone please help?
    Best regards,
    Abhinava

    Is there a technical name? Something like BUS1234.
    Any way, from the code snippet you show above, I think there might be some confusion. The way I understand it is that you attach BOR objects to Cases (whatever case means). This is where the method BOR_OBJECTS_GET comes. If you want to attach PDF files, then, you will need a means to extract these files as binary internal tables. Your code below does not seem to do that. So, the BOR object attached to the case is different than the actual attached PDF file.
    If your BOR object provides a method to display a PDF file, then, you might want to look into that method's code and see how the PDF is extracted.

  • How to attach a smartform in BOR object

    Hi,
    I want to know how to attach a z smartform to BOR object? I tried to search out here but not able to have the result.
    Kindly provide the guidelines for it....
    Regards,
    Rickky

    Hi,
    In the BOR object, create a method say display_SF. Now in the ABAP properties for that method give "OTHER" option.
    Now in the BOR object, you can find the program which is used. Inside that program, You need to write the code to fetch the required data (ONLY BASIC REQUIRED DATA WILL BE ENOUGH) and call the smartform by passing all the print parameters and all the required data for that smartform.
    Now inside the smartform, with imported required data, you can write all the logic and data fetch etc for the printouts.
    The following sysntax can be used to fetch the required data into the method and can use to pass the same while calling the smartform.
    SWC_GET_ELEMENT CONTAINER 'Plant' PLANT.
    Regards,
    Harish

  • Workflow : attributes  and methods in BOR

    Hi to all,
         I need to create a custom attribute in custom BOR object. I want to put some value in custom attribute by using select statement . where do i write the code for that attribute in BOR. In standard methods i have seen that ex: gw_purchase = object-key-number   wt is that object-key- number. wt is the value does this holds
    so any one  please explain me  with details.

    Hi,
    methods in BOR are piece of codes that you execute in runtime by calling them in workflow. So when you check the box object method with dialog, such methods need to processed by user i.e; workitem agents. If you don't check this checkbox, the piece of code (method) will you be executed in the background without sending the workitem to user.
    Let me know if you still have doubts.
    Regards,
    Raj

  • How to use BOR object?

    Hello,
    We have never used a BOR object. We want use FIPP object. How can we do it? How can we call the Post method?
    Thanks a lot.
    Edited by: LM on Sep 8, 2008 11:07 AM

    Hi
    Refer to the links,
    Probel with POST method of FIPP
    FIPP Workflow
    Regards
    Sumit Agarwal

  • About create instance of a BOR Object

    hi expert
    I do hope any one can help me out of trouble...
    when I want to use a method of a BOR Object, I find the method is an instance dependent method, so I have to create an instance for the BOR Object to initialize the key field, right ? but I do not know how to create , how to use a instance-dependent method.....
    can any one heple me ????

    Hi
    Goto SWO1 Tcode
    enter the main Object (say BUS2032 -sales order)
    press subtype button
    enter ZBus2032 and program(some Z), name, description, application (V) etc
    save ,  activate
    If you want you can create your own method  or event by keeping the cursor on the events or methods
    generate the program, says errors go to the program and generate
    implement the object method and object and release it.
    Now it is available
    Do the delegation type for this object by replacing this Z object in the place of Std object, so that all the methods of std are transferred to the copied one.
    Now creata a Task and use this Object and its method.
    define the triggereing event and define Binding etc and use
    Regards
    Anji

  • BOR object creation

    Hi
      I am creating new BOR object in the bor object defined new key field as matnr when i am trying to release it and before it i have implemented it . it is showing information message no default attribute defined for  the object type

    take /pass any one of ur methods.
    regards
    prabhu

  • How to link bor object to Archive object

    I would like to convert normal file to Archive file using ARCHIV_CREATE_DIALOG_META it is giving
    error there is no link  between bor object and Archive object .

    Based on your other questions I assume you mean either in the workflow or in a method. First of all you should read the FAQ and the guidelines for the forums.
    Converting the object from a subtype to its parent type in a method is achievable by using some of the macros. You can even make a generic solution for this (e.g. a function module).
    Use SWC_GET_OBJECT_KEY to get the object key.
    The attribute OjectType of your object is itself an object. It has an attribute Parent which references another object. The key of this object is the name of the object type.
    Thus you have everything you need to create a new object reference with a type that is the parent object type of your current object; you have the key (which must be identical as this is a subtype) and the object type.

Maybe you are looking for

  • Apex application registered with sso as partner application

    We have 1 apex app registered with sso and working properly. I just registered a new apex application with sso. when i authenticate through sso, it directs me to the originally registered application. I went in through the portal administrator app an

  • 2 weeks without Broadband

    Hi, Can anyone help me or offer advice as I'm at my wits end with BT ! Have been a broadband customer of theirs for years without any problems, 2 weeks ago we decided to change our package to include BT vision, the day after this our broadband connec

  • Bex Browser performance

    Hello, Is there a performance impact in using Bex browser as opposed to Bex analyzer to run a query? I heard from someone that SAP is moving away from BEX Browser. Is this correct? cheers Vijay

  • A way to re-install Mail without a full system reinstall?

    So, I did something dumb and deleted the Mail program. I was thinking I would just restore it from the disks that came with my iBook but the only option that gives me is a complete systems software reinstall. I don't want to do that for a number of r

  • DateWithTimeIntervalSince1970 and Time Zone issues

    Hi I've got a scenario where I need to take 'dates' in by the user. These dates are then stored into a db using timeIntervalSince1970 However these dates need to be absolute and not influenced by Timezones. So if a user picked 20 Nov 2009 for a Holid