2007 Jun 27 7:53 AM
Hi,
I need to put an authority check before saving in Tcode VK11.
I used BADI SD_COND_SAVE_A to put the checking. I needed to output a message then go back to the same screen with the entered values in the screen still in it.
How Can I make the program go back to the screen with its values.
Below is my code:
AUTHORITY-CHECK OBJECT 'V_KONH_VKO'
ID 'ACTVT' FIELD c_activity
ID 'VTWEG' FIELD v_spart.
IF sy-subrc NE 0.
MESSAGE w012(zsd) WITH v_material.
ENDIF.
Thanks in advance!
Regards,
Marco
2007 Jun 27 8:04 AM
Hi Marco,
Try with this
IF sy-subrc NE 0.
MESSAGE w012(zsd) WITH v_material.
LEAVE TO SCREEN XXX.
ENDIF.
Hope this helps you. Reply for queries, shall post the updates.
Regards.
Kumar.
Hi,
I need to put an authority check before saving in Tcode VK11.
I used BADI SD_COND_SAVE_A to put the checking. I needed to output a message then go back to the same screen with the entered values in the screen still in it.
How Can I make the program go back to the screen with its values.
Below is my code:
AUTHORITY-CHECK OBJECT 'V_KONH_VKO'
ID 'ACTVT' FIELD c_activity
ID 'VTWEG' FIELD v_spart.
IF sy-subrc NE 0.
MESSAGE w012(zsd) WITH v_material.
ENDIF.
Thanks in advance!
Regards,
Marco
2007 Jun 27 8:04 AM
Hi Marco,
Try with this
IF sy-subrc NE 0.
MESSAGE w012(zsd) WITH v_material.
LEAVE TO SCREEN XXX.
ENDIF.
Hope this helps you. Reply for queries, shall post the updates.
Regards.
Kumar.
2007 Jun 27 8:12 AM
Hi Kumar,
Thanks for the reply.
This is what Im looking for. But unfortunately it is having an error message ($$00000001 in function group) when ever I would change the values and hit the save button again.
When I debug it, whats happening is that an internal table is not getting refresh in this process thus calling the error message. There is no way I can refresh this table because it is not present in the BADI.
| User | Count |
|---|---|
| 4 | |
| 2 | |
| 2 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |