‎2010 Sep 24 6:26 AM
Hi Gurus,
I have one query.I want to do the validation for the field SORT2 in XD01,XD02 for that I am using exit EXIT_SAPMF02D_001
& BADI CUSTOMER_ADD_DATA but its not working properly as in import parameter of FM structures don't have SORT2 field ? can anybody suggest any BADI or some other user exit ?
Thanks,
Sachin.
Moderator message: please use more descriptive subject lines from now on.
Edited by: Thomas Zloch on Sep 24, 2010 9:27 AM
‎2010 Sep 24 7:10 AM
Hi,
Try with this coding.
CONSTANTS : c_sort2(15) TYPE c VALUE '(MF02DFD0)SORT2'.
FIELD-SYMBOLS : <fs1> TYPE C.
ASSIGN (c_sort2) TO <fs1>.
Now you can use <fs1> similar to SORT2.
Regards,
Srini.
‎2010 Sep 24 7:21 AM
Hi,
Use: BADI --> ADDRESS_CHECK
Method- Z_ADDRESS_CHECK
try like this.
DATA: lv_addrnumber TYPE ad_addrnum,
lv_error TYPE string,
lv_sort1 TYPE ad_sort1,
lv_sort2 TYPE ad_sort2.
FIELD-SYMBOLS :
IF ( sy-tcode = 'XD01' ) OR ( sy-tcode = 'XD02' ).
SELECT
IF sy-subrc NE 0.
Error message.
Endif.
‎2010 Sep 24 8:23 AM
Hi,
you can't find the field SORT2 in the exit EXIT_SAPMF02D_001 & BADI CUSTOMER_ADD_DATA , because these exits are not correct for your issue.
SORT2 is a field of the table ADRP of the Central Address Management.
The address validation routines are the following:
Enhancements:
SZRS0003 Address check - Interface to external providers
BAdIs:
ADDRESS_CHECK Business Address Services
but I cannot see the right one that fits your issue.
In my opinion a [field exit|http://wiki.sdn.sap.com/wiki/display/ABAP/Field+exits] on the Field/Data Elemnt SORT2 could be a good chance.
Regards,
Andrea
‎2011 Aug 30 8:54 AM