‎2011 Aug 03 5:14 PM
Hi Experts,
I am posting FB01 using SHDB.
I run FB01...the screen I get is Post document header Data ...I enter required data and press enter.
Enter G/L account document : Add asset item screen is displayed....again I make entries...and press enter...a pop-up appears...name CODING BLCOK...and asks for entering WBS element.
my problem is that when I directly use FB01 then no Pop-up appears and transaction posts document successfully...but if record FB01 using SHDB then pop-up appears...
could please tell me why it is happening...why such dual behaviour...please reply.
Thanks in Advance.
Ratnesh
‎2011 Aug 03 5:51 PM
Hi Ratnesh,
Can you try BAPI_ACC_DOCUMENT_POST instead of BDC,if possible?
Cheers
Amit
‎2011 Aug 03 7:16 PM
‎2011 Aug 04 5:09 AM
Hi Ratnesh,
Please check while recording where that pop up called. Try to skip that screen and see.
Regards,
Madhu.
‎2011 Aug 04 10:16 AM
Hi Ratnesh,
there can be many reasons why it doesn't behave identically. The most probable is that the FB01 standard program tests the SY-BINPT system flag which is 'X' when execution is via batch input. That is not the only one (I have written a wiki about what can be the reason ). Using SHDB, you can record/play by forcing SY-BINPT = space, using option "not a batch input session". In that case, the screens may be different, so I recommend you to record again from scratch, then play.
If it doesn't work, then you should have a look at the wiki, that may not solve but you can understand where is the difference (I know it is difficult to read it, so tell me what is not clear).
Using a BAPI is of course always the best option other BDC, if it exists/or is possible.
BR
Sandra
‎2011 Aug 11 10:33 AM
Hi Ratnesh,
This Happens because, FB01 is standard program, and when you arerecording coding block which is screen number cobl-002 will trigger automatically as there can be some mandatory fileds to be filled in for some scneario. so it will get triggered for GL postings only. if you need to pass some field value just pass it on else ignore and proceed with the next screen.
If you check further, the screens called for GL posting during recording would be 300(first screen)-002(coding block)-330(for more data).
Where as for customer and vendor posting this will be not come into picture.
hope this helps you.
Best Regards
Manoj
Edited by: Manoj Kumar T on Aug 11, 2011 11:33 AM