12-29-2014 2:53 AM
Hi Experts,
I have a requirement, wherein I need to do a BDC recording in a Proxy method.
FORM-ENDFORM cannot be used inside a METHOD-ENDMETHOD.
Can you please guide me on how modularization and re usability can be achieved in a proxy method.
Thanks,
Anil
12-29-2014 3:03 AM
I would suggest that you create an FM for the BDC recording and then call that FM under your proxy method.
Additional advantage of this approach is that it would make way for better error handling
12-29-2014 3:35 AM
Hi Pulkit,
Good idea.
I will try this one and let you know how it is working.
Also can you let me know if I can use an include program in the proxy?
When I try to use this, It is not allowing since there is no main program.
Thanks,
Anil
12-29-2014 3:44 AM
You cannot use an include program in a proxy method, because it is basically a method of a class.
However, you can create a separate program and then call routine of the program in the proxy method using perform <routine_name> in program <program_name> [parameter list] if found.
12-29-2014 4:16 AM
Hi,
Try to call the BDC using methods in the class,
for reference use below:
http://scn.sap.com/community/abap/blog/2013/10/11/bdc-program-with-ooabap
12-29-2014 6:25 AM
Hi Anil,
The same kind of issue i faced long back and written all BDC code in OO-ABAP. the same I wrote in a blog, pls check the blog which was refered by Kiran Jasti.
Thanks
Raju C D