Quantcast
Channel: SCN: Message List
Viewing all articles
Browse latest Browse all 9159

Re: field validations and save order in salesorder using order_save badi

$
0
0

Hi you need to use the below codee fro CRM_ORDER_READ_OW

 

INSERT iv_guid INTO TABLE lt_header_guid.
ls_requested = 'PARTNER'.
INSERT ls_requested INTO TABLE lt_req_obj.
CALL FUNCTION 'CRM_ORDER_READ_OW'
    EXPORTING
      it_header_guid       = lt_header_guid
      iv_mode              = 'A'
      it_requested_objects = lt_req_obj
    IMPORTING     
      et_partner           = lt_partner     
    CHANGING
      cv_log_handle        = lv_log_handle
    EXCEPTIONS
      document_not_found   = 1
      error_occurred       = 2
      document_locked      = 3
      no_change_authority  = 4
      no_display_authority = 5
      no_change_allowed    = 6
      OTHERS               = 7.
  IF sy-subrc <> 0.
* Implement suitable error handling here
  ENDIF.
READ TABLE lt_partner INTO ls_partner WITH KEY  partner_fct = ls_partner1-partner_fct."partner fct for sold to party
IF sy-subrc IS NOT INITIAL.

endif.

ls_partner-partner_no is sold to party partner no do your validation with that partner no.

 

Regards,

Deepika.


Viewing all articles
Browse latest Browse all 9159

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>