Tuesday, July 15, 2008

How to Print SAP Report/Forms in PDF Format

dah lama tak buat posting pasal SAP ABAP...kali ni kita belajar 'How to Print SAP Report/Forms in PDF Format'..hehe...

actually there is a standard program for this purpose...below are the steps how to print it (sorry this time no captured image)
  • run the report that you wish to execute in background (Program -> Execute in Background)...for forms print the form and send it to spool...
  • go to tcode SP02 and get the spool no
  • run program RSTXPDFT4 , enter the spool no, tick 'Download PDF File' and execute
  • a pop-up window will appear...select which folder you are intent to save and save it
  • finish (^,^)

Smartforms - page break

Have you ever got a page break problem in smartform? The item text should be start in page 1 and continue to page 2...but it doesn't work...the problem is something like this...

the item text should be start in page 1...but...

it starts in page 2...it happens when not enough space in page 1...

so the solution is...

double click TABLE in MAIN window...

click button DETAILS on the right pane...

untick NO PAGE BREAK which LINE TYPE that you are using

tadaaa...now the item text appear in page 1...

and continue with page 2...

is this article helpful? please leave your comment...:)



How to Debug Smartforms

Yesterday Kak Mus came to me. She said something wrong with invoice form. User cannot print and preview it. The problem is she cannot simulate the same problem in DEV. So that means I had to debug in QAS. Woo..very tough because the easiest way to debug is to add break line with your user ID in the coding.

add 'break user_id' in your coding

I have no authorization to change the program in QAS, so I used function module to debug it. Kak Herma taught me about this. Thanks Kak Herma. It was really useful.

click Environment > Function Module Name


a pop-up window will appear with function module name...copy it..


go to tcode SE37 and display the function module and break anywhere in the coding...

I found the error message in the function module. Even though the message is not specific, but at least I got a clue what and where the error came from.

Sometimes smartforms are ‘crazy’.Haha.Very difficult to debug it rather than sapscript. So above tips may help who are working with ABAP to debug smartforms.hehe.

Is this article helpful? Please leave comment... :)