‎2006 May 05 6:43 AM
Hi,
I would like to know if its possible to create a report
program from a function module instead of going to SE38?
I want to write a function module which takes Report Pgm
Name and the Source Code as its input parameters and
create the report pgm.
Is any function available in SAP for creating a report
program? If so wat is it?
Ps: I do not want to generate a sub-routine pool.
Thanks in advance.
‎2006 May 05 6:46 AM
Hi !
Yes it is possible.
See the Online Help to the ABAP-Commands:
INSERT REPORT and GENERATE REPORT.
With INSERT REPORT you can cerate a ABAP-Report with it's code is dynamically stored in an internal table.
But... be shure that you don't import a "trojan" in this way ! If your function is a remote callable FM it would be a bit risky to create any report that comes via your function...
Regards
Rainer
Some points would be fine if that helps a bit.
‎2006 May 05 6:47 AM
The report writer is same as the SE38 screen you can create a report as you are doing in the SAP editor.
Here also you can go for se38 and you can write your report as per your requirement.
Tcode for report writer is FGRW
for report writer....
http://www.virtuosollc.com/PDF/Get_Reporter.pdf
download pdf from this link it is very helpful
‎2006 May 05 6:51 AM
HI
GOOD
NO I DONT THINK YOU CAN CREATE A REPORT WITHOUT THE HELP OF SE38 OR SE80.
THERE IS NO SUCH FUNCTION MODULE WHO WILL HELP YOU TO CREATE A REPORT.
YOU CAN CREATE A FUNCTRION MODULE BUT I DONT THINK YOU CAN TAKE THE SOURCE CODE AS THE INPUT PARAMETER.
THANKS
MRUTYUN
‎2006 May 05 6:52 AM
hi ravi,
why dont you develop your code thru se38??
Any business reason behind this?
If this is not the case then i would advice you to go thru se38..
check the below link..
http://help.sap.com/saphelp_47x200/helpdata/en/d3/2e974d35c511d1829f0000e829fbfe/frameset.htm
Cheers,
Abdul Hakim
‎2006 May 05 6:59 AM
Hi,
If you are planning on to write a report in a function and make it remote enabled so that you can call it from a external system that will not be possible. RFC functions cannot call anything where there is output being written on to the screen.
Regards,
Ravi
Note : Please mark the helpful posts.
‎2006 May 05 7:00 AM
Hi anandaraja,
1. Simple.
2. we have to use the command
INSERT REPORT 'ZPROG' from itab.
3. just copy paste in new program.
It will create a new program
'ZAM_TEMP05'.
(this new program will just print amit)
4. U can use this code in the code of your FM.
(by passing programname, and source in the form
on internal table thru TABLES parameter)
5.
REPORT ABC.
*----
DATA : BEGIN OF ITAB OCCURS 0,
F(72) TYPE C,
END OF ITAB.
*----
ITAB-F = 'REPORT ABC.'.
APPEND ITAB.
ITAB-F = 'WRITE '' AMIT '' .'.
APPEND ITAB.
*----
INSERT REPORT 'ZAM_TEMP05' FROM ITAB.
regards,
amit m.