Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

Can't seem to get COM_PRODUCT_MAINTAIN_STATUS to work

Hello,

I have written a progran around COM_PRODUCT_MAINTAIN_STATUS and thought I had developed it correctly. While I'm not getting any errors, I cannot seem to get it to update a product's status. Here's a snippet of the code...

CLEAR lv_CONTEXT.

lv_CONTEXT-TEXT1 = 'Updating Status of Product'.

lv_CONTEXT-TEXT2 = wa_PRODUCT_MAINTENANCE-PRODUCT_ID.

lv_CONTEXT-TEXT3 = 'To'.

lv_CONTEXT-TEXT4 = wa_PRODUCT_MAINTENANCE-STATUS.

CALL FUNCTION 'COM_PRD_OPEN_LOG'

EXPORTING

IS_CONTEXT = lv_CONTEXT

IMPORTING

EV_LOGHANDLE = b_APPLICATION_LOG

.

CALL FUNCTION 'COM_PRODUCT_MAINTAIN_STATUS'

EXPORTING

IV_PRODUCT_GUID = b_PRODUCT_GUID

IT_STATUS = b_STATUS_MAINTAIN

IV_APPLICATION_LOG = b_APPLICATION_LOG

  • IS_STATUS_ACTIVITY =

.

COMMIT WORK AND WAIT.

SELECT SINGLE CHGNR FROM CRM_JEST

INTO lv_CHGNR

WHERE OBJNR = b_PRODUCT_GUID

and STAT = wa_PRODUCT_MAINTENANCE-STATUS

and INACT = SPACE.

Any idea why this is not working?

Points awarded accordingly.

Regards, Dean.

Not what you were looking for? View more on this topic or Ask a question