Skip to Content

Recently I found myself as a SAPLink user- a client of mine was not offering a remote access and at the same time they were expecting some pilot solution ASAP. So I had to do developments in a comercially accessible IDES system and then tranport it to the client’s. And as Workflow was involved I had to trasnport not only conventional ABAP code but also a number of Workflow objects. Unfortunately I did not find a plugin for Workflow objects and so I had to develop one.

Those who need it feel free to download attached XML file which is actually a NUGGET containing 4 classes for export/import Workflow objects: Standard Tasks (object PDTS), Agent determination rules (object PDAC), and Workflow templates (object PDWS).

This all is just out of the oven, so let’s say it’s in “alpha”.

Tested on NW 7.02.

To report this post you need to login first.

42 Comments

You must be Logged on to comment or reply to a post.

  1. Katrice Hawkins

    Thank you Sergey Korolev.

    You have reduced an effort by proiving the attachment.But when i imported that WF plugin and after activating the imported classed individually and after executing the program ZSAPLINK, it is giving dump.

        An exception occurred that is explained in detail belo

        The exception, which is assigned to class ‘CX_SY_CREAT

         caught in

        procedure “GETPLUGINS” “(METHOD)”, nor was it propagat

        Since the caller of the procedure could not have antic

        exception would occur, the current program is terminat

        The reason for the exception is:

        The dynamically specified class “ZSAPLINK_WF” at CREAT

         You

        cannot create instances from abstract classes.

        Note: A class is ‘abstract’ if it was defined with the

        ‘ABSTRACT’, for example, because one or several method

        implemented, and are to be implemented in a subclass.

    BR

    Katrice

    (0) 
    1. Sergey Korolev Post author

      Hello Katrice,

      Seems you have an old version of ZSAPLINK class. In the varsion I have there is a TRY… CATCH block around plugin instanciation statement in GETPLUGINS method:

      TRY.

               CREATE OBJECT classobject

                 TYPE

                   (clsname)

                 EXPORTING

                   name      = ‘foo’.

               objtype = classobject->getobjecttype( ).

             CATCH cx_root.

               CONTINUE.

           ENDTRY.

      Either download more recent version or fix it yourself.

      HTH.

      (0) 
      1. Katrice Hawkins

        Yes Sergey,

        You are correct.When i corrected the code as shown above,It works.But in ZSAPLINK program “export object to slinkee” in Slinkee tab, i cannot see any object types related to workflow.

        Thanks

        Katrice

        (0) 
          1. Ravi Kumar

            Hi Sergey,


            Thanks for your valuable contributions.

            I have query regarding the number range while replicating the Wflow objects in the target system.

            In general, all workflow objects produce unique numbers during creation.

            Would these classes able to assign new number range for to be created Wflow objects using SAPLink.

            Please clarify.


            Regards,

            Ravi



            (0) 
  2. Amruth Kumar Ashok kumar

    Hi Gregor,

    I am looking forward to create nuggets for Workflow Objects .

    I uploaded the .XML file in this thread .but am not able to activate the plugin classes , i am getting Errors while attempting to activate them .

    (0) 
  3. Amruth Kumar Ashok kumar

    An exception occurred that is explained in detail below.

    Error :


    CREATE OBJECT on abstract class not possible.

    Error Analysis :


    The exception, which is assigned to class ‘CX_SY_CREATE_OBJECT_ERROR’, was not

      caught in procedure “GETPLUGINS” “(METHOD)”, nor was it propagated by a RAISING clause.

    Since the caller of the procedure could not have anticipated that the exception would occur, the current program is terminated. The reason for the exception is: The dynamically specified class “ZSAPLINK_WF” at CREATE OBJECT is ‘abstract’.

    You cannot create instances from abstract classes. Note: A class is ‘abstract’ if it was defined with the addition  ‘ABSTRACT’, for example, because one or several methods are not

    implemented, and are to be implemented in a subclass.

    (0) 
    1. Amruth Kumar Ashok kumar

      I followed the above guided steps of using a try catch 

      I am not getting the above dump on GETPLUGIN method of ZSAPLINK class.

      but still am not able to see the “workflow object type”  during the execution of saplink report

      (0) 
      1. Amruth Kumar Ashok kumar

        Hi Gregor,

        And error during activation of individual classes exists in source server .

        Sorry i think am posting lot of issues..

        but am facing these issues , need your support…

        Thank you .

        (0) 
  4. Amruth Kumar Ashok kumar

    Hi Gregor,

    In another server I get following error while trying to activate the Individual class

    Class ZSAPLINK_WF_TEMPLATE

    Error :

    Protected section Method “AFTER_SAVE” is not declared or inherited in class   “ZSAPLINK_WF_TEMPLATE”.

     

    Class ZSAPLINK_WF:

    Error :

    Method APPEND_TABLE_NODE : Unable to interpret “I_NODE”.

    Possible causes of error: Incorrect spelling or comma error.    

       

    Class ZSAPLINK_WF_STASK

    Error :

    Protected section – 5     

    Method “FILL_ROOT_NODE” is not declared or inherited in class ZSAPLINK_WF_STASK”

    Class ZSAPLINK_WF_ACTOR_RULE:

    Error :

    Protected section – 5     

      Method “CREATE_WF_CNT_INSTANCE” is not declared or inherited in class ZSAPLINK_WF_ACTOR_RULE

    (0) 
        1. Sergey Korolev Post author

          Hi Amruth,

          Open System -> status again and click magnifying glass button under Component version. See what says for SAP_ABA and SAP_BASIS in columns Version and Level.

          (0) 
          1. Amruth Kumar Ashok kumar

            Hi Sergey,

            Server 1:

                                           R              L

            SAP_BASIS            731         0002

            SAP_ABA               731         0002

            server 2 :

                                         R             L

            SAP_ABA            700         0013

            SAP_BASIS         700         0014

            (0) 
    1. Sergey Korolev Post author

      Hi Amruth,

      They should be at the bottom of the list: PDAC for Agent determination rule, PDTS for Standard task, and PDWS for Workflow template.

      (0) 
      1. Amruth Kumar Ashok kumar

        🙂 , No am not getting your mentioned object type in the F4 help of ZSAPLINK  Program ,

        I was gettig dump while running the ZSAPLINK  Program .So I used the Try….Catch in  ZSAPLINK Class,as mentioned in the  thread above

        Like Bellow………..

        TRY.

                 CREATE OBJECT classobject

                   TYPE

                     (clsname)

                   EXPORTING

                     name      = ‘foo’.

                 objtype = classobject->getobjecttype( ).

               CATCH cx_root.

                 CONTINUE.

             ENDTRY.

        (0) 
  5. Amruth Kumar Ashok kumar

    I am not finding workflow related object types in the F4 help of the object_types field. in the selection screen of zsaplink program

    I was gettig dump while running the ZSAPLINK  Program .So I used the Try….Catch in  ZSAPLINK Class,as mentioned in the  thread above .

    Kindly Guide me on what to be done .

    code changes made to ZSAPLINK  Program

    TRY.

             CREATE OBJECT classobject

               TYPE

                 (clsname)

               EXPORTING

                 name      = ‘foo’.

             objtype = classobject->getobjecttype( ).

           CATCH cx_root.

             CONTINUE.

         ENDTRY.

    (0) 
    1. Sergey Korolev Post author

      Hi Amruth,

      Actually it should be enough to activate 4 classes:
      ZSAPLINK_WF

      ZSAPLINK_WF_ACTOR_RULE

      ZSAPLINK_WF_STASK

      ZSAPLINK_WF_TEMPLATE

      After that ZSAPLINK report should recognize object type PDWS, PDTS, and PDAC.

      (0) 
        1. Sergey Korolev Post author

          Hello Wallace,

          Cannot reproduce the case. What SAP ABAP version are you on? Did you try to restart ZSAPLINK report after activating classes?

          (0) 
          1. Wallace Ferreira e Silva

            Hello Sergey,

            I´m activated ZSAPLINK reporte after activating classes.

            SapLink Version : SAPlink_install-0.1.4

            SAP Abap :

                                      R         L

            SAP_basis       731       007

            SAP_aba         731       007

            Thanks in advance.

            (0) 
            1. Sergey Korolev Post author

              Hello Wallace,

              Unfortunately I don’t have 7.31 at hand and thus I am afraid cannot help with the issue.
              When creating the list of available objects ZSAPLINK tries to create an instance of each plugin class inside TRY…CATCH cx_root block. Apparently there is something incompatible with 7.31 in the code. If you have time you can check this by testing one of classes (e.g. ZSAPLINK_WF_STASK) in SE24 separately. It should report some error when creating instance.


              (0) 
              1. Wallace Ferreira e Silva

                Hi Sergey,

                My Master co-work made some workaround changes in zsaplink class GETPLUGINS method, like that code bellow :

                     tabletypelineobject = objtype.

                     APPEND tabletypeline TO tabletypesin.

                     IF classlineclsname = ‘ZSAPLINK_WF’.

                       FREE tabletypesin.

                       tabletypelineobject = ‘PDAC’.

                       APPEND tabletypeline TO tabletypesin.

                       tabletypelineobject = ‘PDTG’.

                       APPEND tabletypeline TO tabletypesin.

                       tabletypelineobject = ‘PDTS’.

                       APPEND tabletypeline TO tabletypesin.

                       tabletypelineobject = ‘PDWA’.

                       APPEND tabletypeline TO tabletypesin.

                       tabletypelineobject = ‘PDWS’.

                       APPEND tabletypeline TO tabletypesin.

                     ENDIF.

                     CALL FUNCTION ‘TRINT_OBJECT_TABLE’

                       TABLES

                         tt_types_in  = tabletypesin

                         tt_types_out = tabletypesout.

                (0) 
                1. Vinicius Eustaquio

                  Thanks Wallace! In this case, the return of the GET_OTYPE method of the ZSAPLINK_WF class should be one table category (array). However this change reflected in the other classes (plugins). But, the GETPLUGINS method of the ZSAPLINK class must be prepared. I changed quickly for solved my problem. But is not  better solution, ok?

                  (0) 
        2. Juan David Lopez Santa

          Append de code below in zsaplink method GETPLUGINS:

          ———————————————–

          SELECT * FROM vseoextend APPENDING TABLE classlist

                 WHERE refclsname = ‘ZSAPLINK_WF’

                 AND version = ‘1’.

          ——————————-

          Now the program see the class:

          ZSAPLINK_WF_ACTOR_RULE

          ZSAPLINK_WF_STASK

          ZSAPLINK_WF_TEMPLATE

          and show PDWS, PDTS and PDAC objects in search help.

          (0) 
  6. Lino Lopes

    Or even better:

    Instead of appending the above code in the GETPLUGINS method of class ZSAPLINK, simply modify the “SELECT * FROM VSEOEXTEND …” command at the very beginning of the same method and replace:

    refclsname = ‘ZSAPLINK’

    in WHERE clause by:

    refclsname LIKE ‘ZSAPLINK%’

    Then, the only restriction would be that all SAPLINK plugin classes would have to be a descendant of classes whose names begin with ZSAPLINK.

    This is exactly the case with ZSAPLINK_WH, This class, which descends from ZSAPLINK, is the superclass of all three workflow-related plugin classes.

    (0) 
  7. Lino Lopes

    Hi All,

    Since workflows and BORs often work together, I have developed a SAPLINK plugin to deal with BOR objects.

    I couldn’t find a way to upload it here, so anyone who wants it, just drop me a line and I’ll email it to you: lino@hr.com.br

    Cheers!

    (0) 
    1. Ravi Kumar

      Hi Lino,

      It’s great to see that for BOR objects SAPLink plugin is available. Please send it to my mail id sunrays08@gmail.com.

      I request you to make this plugin available on the SDN or any web portal for everyone.

      Appreciate your efforts.

      Thanks,

      Ravi

      (0) 
  8. Mithun Kumar

    I came in too late to this blog. It seems the attachment is removed already.

    Dear Sergei, Any other place I can download and use your plugin, please? I’ve the latest SAPlink installed.

    (0) 

Leave a Reply