2007 Jun 03 1:55 PM
Hi All
I have a requirement for setting a lock for dunning on contract for 1 day with a lock reason of 'X'. Can somebody guide me on this...
Thanks in advance
Jai
Hi All
I have a requirement for setting a lock for dunning on contract for 1 day with a lock reason of 'X'. Can somebody guide me on this...
Thanks in advance
Jai
2007 Jun 03 2:29 PM
use Sm01 Transaction to lock F150 Transaction.
Reward Points if it is helpful
Thanks
Seshu
2007 Jun 03 2:55 PM
Hi Jaideep,
you mention a "contract" - so this my be contract accounting.
If so, the lock reason X must be configured in customizing. You can set (and delete) the lock manually in contract master data, as I remember in payment section.
The result can be checked in DB table DFKKLOCKS.Do this to get all parameters you need for function calls.
In program, use FUNCTION 'FKK_S_LOCK_GET_FOR_GPART_VKONT' to read the locksfor the PROID and LOTYP as seen in DFKKLOCKS. Then use FUNCTION 'FKK_S_LOCK_CREATE' to set the lock with fdate = sy-datum and tdate = sy-datum + 1.
You may use this form to create the lock object LOOBJ1:
<pre>
----
Form LOCKS_LOOBJ1_CREATE
----
FORM locks_loobj1_create USING p_vkont LIKE fkkvkp-vkont
p_gpart LIKE fkkvkp-gpart
CHANGING p_loobj1 LIKE dfkklocks-loobj1.
p_loobj1+0(12) = p_vkont.
p_loobj1+12(10) = p_gpart.
ENDFORM. " LOCKS_LOOBJ1_CREATE
</pre>
Good luck!
Regards,
Clemens
2007 Jun 03 4:51 PM
Hi Li
Thanks for wonderful guidance... I was searching for it for last 1 hour and also found the same what u have just explained above and even implemented it. The only difference is that that i have not read the old locks for the CA in my Report.
Is that necessary?? I mean i have not used that logic, should i??
Thanks and Regards
Jai
2007 Jun 03 4:57 PM
Hi Jaideep,
reading the existing locks can be used to make sure that the lock you want to set does not yet exist.
We use it for some more complex logic like "do not delete lock of type A" if a lock of type B exists.
Regards,
Clemens
| User | Count |
|---|---|
| 3 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |