Sales Order Check FM -Objtype Error.

Deanna Teo deannate at au1.ibm.com
Wed Nov 7 17:54:31 EST 2001


Hi Jocelyn!
 
Thanks for your help. You are right, the interface is specific. I had to
add in the EVENT_CONTAINER within my function module and set the function
module to RFC enabled and it worked.
I tried using the SWB_COND Workflow Start Conditions but it was not enough
for me for the check conditions. I needed to check extra things such as the
system status of the document first before triggering the workflow.
 
Thanks again for your help!
 
Regards,
Deanna Teo
Enterprise Resources
IBM GSA
Mobile: 0421 054 593
 
 
 
 
 
                    "Dart, Jocelyn"
                    <jocelyn.dart at sap.co       To:     SAP-WUG at MITVMA.MIT.EDU
                    m>                         cc:
                    Sent by: SAP               Subject:     Re: Sales Order Check FM -Objtype Error.
                    Workflow
                    <Owner-SAP-WUG at MITVM
                    A.MIT.EDU>
 
 
                    07/11/2001 04:37 PM
                    Please respond to
                    "SAP Workflow Users'
                    Group"
 
 
 
 
 
Hi Donna,
Firstly, as you are in CRM, it's better to use the workflow start
conditions
(transaction SWB_COND) to set up a logical expression to be checked before
starting the workflow rather than code your own check function module.
You can put very complex logical expressions into the start conditions so
you should only create your own check function module as a last resort.
 
If you still want to use your check function module the interface should be
as follows:
 
*"  IMPORTING
*"     VALUE(OBJTYPE) LIKE  SWETYPECOU-OBJTYPE
*"     VALUE(OBJKEY) LIKE  SWEINSTCOU-OBJKEY
*"     VALUE(EVENT) LIKE  SWETYPECOU-EVENT
*"     VALUE(RECTYPE) LIKE  SWETYPECOU-RECTYPE
*"  TABLES
*"      EVENT_CONTAINER STRUCTURE  SWCONT
*"  EXCEPTIONS
*"      ...
 
I.e. Don't forget the event container.
The interface is VERY specific.
Regards,
        Jocelyn Dart
Consultant (EBP, BBP, Ecommerce, Internet Transaction Server, Workflow)
SAP Australia
Email jocelyn.dart at sap.com <mailto:jocelyn.dart at sap.com>
Tel: +61 412 390 267
Fax: +61 2 9935 4880
 
 
-----Original Message-----
From: Deanna Teo [mailto:deannate at au1.ibm.com]
Sent: Wednesday, 7 November 2001 3:46 PM
To: SAP-WUG at MITVMA.MIT.EDU
Subject: Sales Order Check FM -Objtype Error.
 
 
Hi!
 
I am trying to place a Check Function Module in 'Type Linkages(transaction
SWETYPV') which I created with my workflow to check for conditions when a
crm sales order is created in the crm box.
 
However, I get a weird error saying that 'Parameter with OBJTYPE has an
invalid reference' and it refuses me to place the check function module.
 
The Parameter 'OBJTYPE' has a reference type of 'SWETYPECOU-OBJTYPE' as
shown below.
 
FUNCTION ZCRM_CHECK_FUNCTION_CREATE_ORD.
*"----------------------------------------------------------------------
*"*"Local interface:
*"  IMPORTING
*"     VALUE(OBJTYPE) TYPE  SWETYPECOU-OBJTYPE
*"     VALUE(OBJKEY) TYPE  SWEINSTCOU-OBJKEY
*"     VALUE(EVENT) TYPE  SWETYPECOU-EVENT
*"     VALUE(RECTYPE) TYPE  SWETYPECOU-RECTYPE
*"  EXCEPTIONS
*"      RAISE_EXCEPTION_ERROR
*"      ORDER_TEMPLATE_STATUS_EXIST
*"----------------------------------------------------------------------
Is there anything wrong? I have done this before in SAP R/3 and I do not
have any problems at all. Anyone has any ideas?
Is there a difference for check function modules in CRM system?
 
Any advise would be appreciated!
 
Thanks!
Deanna Teo
Enterprise Resources
IBM GSA
Mobile: 0421 054 593
 


More information about the SAP-WUG mailing list