Smart form is an output format. It’s just like a ready to print document. We can design the form to be printed in different ways with the requisite information on it. Some examples are Invoices, Purchase Order, Sales Order…
As we all know, there are two entities involved in smart form.
As we all know, there are two entities involved in smart form.
1. Smart form design.
2. Driver program.
Sometimes it happens that the information which needs to get printed on the form is missing or customer wants to display some new information on the form or client wants a change in the design format (Roll-Out Projects) and so on… At that point in time it is important to know from where the data is being retrieved to make the necessary changes. We can find out how, what and from where the data is retrieved through Debugging.
To debug a smart form we must know the smart form name and the driver program associated with it. It’s the functional consultant who will provide us this information. But if we know the smart form name we can find its driver program by
1. NACE Tcode à Output Types à Processing Routines.
2. TNAPR Table à Contents à Form Name (Smart form name).
3. SPRO Tcode.
As for as i know, Smartform can be debugged in four ways.
- By setting breakpoints in the function module.
- By setting breakpoints in the driver program.
- By setting breakpoints in the smartform include program.
- By using popup window debugging technique .
Setting breakpoints in the function module.
Debugging a smart form is just like debugging a function module. To debug a smart form we have to follow the below steps.
- Tcode SMARTFORMS à Enter the smart form name à Goto Environment Menu àFunction Module Name à Copy the Function Module Name (Ex: 1BCDWB/SF00000142)
- Tcode SE37 à Paste the Function Module Name à Put the breakpoints in the required places
- Tcode SMARTFORMS à Enter the smart form name à Test button à Test/Execute à give the Output Device as LP01 à Click on Print preview à Now the debugger session will open at the place where you have put the breakpoints.
Setting breakpoints in the driver program.
In order to set the breakpoints in the driver program,
- Tcode SE38 and provide the program name and display it.
- Put the breakpoints in the relevant places of driver program.
- Try to print the smart form by giving the default printer name. Then the moment you click on print preview button, the smart form will enter the debug mode.
Every time when the smartform is activated a corresponding include program is generated. To find out the corresponding include program follow the below steps.
- Tcode SMARTFORMS à Enter the smart form name à Goto Environment Menu àFunction Module Name à Copy the Function Module Name (Ex: 1BCDWB/SF00000142).
- Goto Tcode SE38 and paste the function module name and before displaying it Just prefix "L" before SF and postfix "F01" after 142. Now the include program name is : 1BCDWB/LSF00000142F01.
- Put the breakpoints in the required places.
- Try to print the smart form by giving the default printer name. Then the moment you click on print preview button, the smart form will enter the debug mode.
We can also use popup window debugging method to debug a smartform and to do that follow the below steps.
No comments:
Post a Comment