Skip to Content

Showing ABAP Class instances in WF "Objects and attachments" list

Hi all,

I have a ABAP class (ZCL_EXAMPLE_WF) which I'm using in a custom Workflow. An instance is passed in when the workflow is created and assigned to a container element. Is it possible to have this object show up in the "Objects and attachments" list when work items are viewed in SBWP? I understand that if this was a BOR business object, it would be added to the

&_ADHOC_OBJECTS&

multi-line container element; if it was a SOFM BO, it would be added to

&_ATTACH_OBJECTS&

. But it is not a BO so it can't be added to the adhoc objects element. Is there another way of having it show up in the list?

thanks, Matthew

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

5 Answers

  • Best Answer
    author's profile photo Former Member
    Former Member
    Posted on Sep 03, 2013 at 12:21 PM

    Matt,

    For the object's instance to be seen as a link under 'Objects and Attachments' of a particular standard task(TSxxx), you need to create a container element of type ZCL_EXAMPLE_WF in the standard task's container and bind the element in the workflow container to the one in the task container. And by implementing the method EXECUTE_DEFAULT_METHOD you can achieve what you need.

    Thanks.

    Vipin.

    Add a comment
    10|10000 characters needed characters exceeded

    • Hi Vipin,

      Thanks for making this clear. I was looking for a way to avoid creating a container element in every task in which I need the instance to be accessible, but it seems that this isn't possible.

      Why SAP haven't implemented this when it is so useful and available for the older Business Objects, is something of a mystery to me!

      thanks,

      Matthew

  • Posted on Aug 18, 2013 at 09:14 AM

    Hello Mathew,

    Create an workflow container object of type ABAP class (ZCL_EXAMPLE_WF) and check if it shows up as an object.

    Regards,

    Sahir.

    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Aug 31, 2013 at 02:53 PM

    Hello Matthew Smith,

    Take a look at workflow template WS17900011 .

    It has class instance as a workflow container element.

    Hope this helps.

    Regards,

    Sahir.

    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Aug 19, 2013 at 08:31 AM

    Hi,

    can you please check the method DEFAULT_ATTRIBUTE_VALUE and EXECUTE_DEFAULT_METHOD implemented or not.

    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Sep 02, 2013 at 05:57 PM

    Hi Matthew,

    when your example class is implementing the interface IF_WORKFLOW, the given instance can be added to the container &_ADHOC_OBJECT&. It will take both: BOR objects, as well as Class instances.

    When the instance is being used as the leading object of the task, i.e. _WI_OBJECTID, it will also show up in the "Objects and attachments" sections.

    Take care

    Florin

    Add a comment
    10|10000 characters needed characters exceeded

    • Hi Matthew,

      that's interesting, as I remember getting it working, as I was using a functional exit for container assignment. In this case there's no syntax-check by the Workflow Builder as the data flow is being coded.

      But thanks for trying this, although it didn't work as expected.

      I'm implementing on SAP ECC 6.0 EnhP 4.

      With the very best wishes

      Florin