Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

How to debug Smartforms?

Former Member
0 Likes
2,696

Hi Gurus,

How to debug Smartforms?

Thanks in Advance

Sri

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
1,823

Please set a break point in side the smartform:

BREAK <USERNAME>.

Then at the time of print/ preview the program stops there.

Example : If you set the break point in initializationas

BREAK <USERNAME>.

Program stops at break point. After that use Serach and set more break points.

-


>Search the program logic/Textelement/Address via search and set the break point at that code.

____________________________________

1) One way to debug smartform is to debug the Function Module of that smartforms.

If you want to debug particular smartform node that the solution would be,

insert a "Program Line" just above the node you want to debug and this program line write a normal abap breakpoint.

So whenever you call the smartforms, it will stop at this breakpoint and you can debug onwards.

2) SFTRACE can be used for debugging SMARTFORMS.

______________________________________

1)goto tcode SFTRACE --> click "trace on"

2) Get the function module name and set break points in function module name.

______________________________________

There is a transaction 'SMARTFORMS_TRACE' (or was it 'SMARTFORMS_TRACE') which will give you quite helpful information.

______________________________________

In SAPSCRIPTS, you can 'Activate the debugger' in SE71 to start the debugging of script.

In SMARTFORMS, you can use BREAK-POINT (coded in any code window node) to initiate debugging of SF.

______________________________________-

SFTRACE can be used for debugging SMARTFORMS.

_______________________________________-

Go in smartforms, put a breakpoint where you want in the generated FM.

Then go in you're PO, go to messages, generated you're output and make sure in further data option 1 is selected.

Then run program rsnast00 with you're form settings, that's it!

You could debug sapscript like that also,

regards,

srinivas

10 REPLIES 10
Read only

Former Member
0 Likes
1,823

hi,

u cannot debug smartforms.

rgds

Read only

0 Likes
1,823

Hi,

If you dont know things please dont reply........

regards,

jinesh.

Read only

Former Member
0 Likes
1,823

Hi,

create a program lines node in smartform and enter the 'BREAK-POINT' statement there.you can debug.

Reward points if helpful,

regards,

jinesh.

Read only

varma_narayana
Active Contributor
0 Likes
1,823

hi

Use the Standard program SFTRACE for debugging smartforms

<b>reward if helpful</b>

Read only

Former Member
0 Likes
1,824

Please set a break point in side the smartform:

BREAK <USERNAME>.

Then at the time of print/ preview the program stops there.

Example : If you set the break point in initializationas

BREAK <USERNAME>.

Program stops at break point. After that use Serach and set more break points.

-


>Search the program logic/Textelement/Address via search and set the break point at that code.

____________________________________

1) One way to debug smartform is to debug the Function Module of that smartforms.

If you want to debug particular smartform node that the solution would be,

insert a "Program Line" just above the node you want to debug and this program line write a normal abap breakpoint.

So whenever you call the smartforms, it will stop at this breakpoint and you can debug onwards.

2) SFTRACE can be used for debugging SMARTFORMS.

______________________________________

1)goto tcode SFTRACE --> click "trace on"

2) Get the function module name and set break points in function module name.

______________________________________

There is a transaction 'SMARTFORMS_TRACE' (or was it 'SMARTFORMS_TRACE') which will give you quite helpful information.

______________________________________

In SAPSCRIPTS, you can 'Activate the debugger' in SE71 to start the debugging of script.

In SMARTFORMS, you can use BREAK-POINT (coded in any code window node) to initiate debugging of SF.

______________________________________-

SFTRACE can be used for debugging SMARTFORMS.

_______________________________________-

Go in smartforms, put a breakpoint where you want in the generated FM.

Then go in you're PO, go to messages, generated you're output and make sure in further data option 1 is selected.

Then run program rsnast00 with you're form settings, that's it!

You could debug sapscript like that also,

regards,

srinivas

Read only

former_member188827
Active Contributor
0 Likes
1,823

open ur smartform, after activating it, in the environment menu, click on function module name.it 'll b sumthing like '/1bcd...'

copy it and go to se37.paste dis name.funtion module 'll b opened. put break point and debug as usual...

plz reward points if it helps

Read only

Former Member
0 Likes
1,823

Yes we can debug scripts and smartforms.

<b>SMARTFORMS DEBUGGING</b>

For smartforms debugging you can do this.

1. Execute the smartform (execute button in SMARTFORMS transaction)

2. Take the generated function module and display it in SE80.

3.Find the smartforms Elements (text elements, windows, code lines, loops) in this and set Soft break points.

Correct name is SMARTFORM_TRACE. You have lots of options for adequate analysis

Tcode - SFTRACE

<b>SCRIPTS DEBUGGING</b>

There are 2 separate kinds of debugging available when you try to debug scripts.

1. Debugging the print program : This is the normal debugging we do for our report programs.

2. Debugging the script itself : You Can debug a SAP Script by activating debugger in two ways:

a .In SE71->Menu->Utilities->Activate Debugger, then debugger will be get activated and when your print program is executing Script Debugger will be in active and you can proceed with your debugging.

b. Goto se38-> RSTXDBUG ->Execute this same as going thru in se71-> Menu, now debugger will be activated.

refer to the link below

http://www.howforge.com/how-to-debugging-sapscript-form

Look at the BLOG here, it is well explained

/people/sudheer.junnuthula2/blog/2007/01/09/script-debugging

Regards,

Pavan

Read only

Former Member
0 Likes
1,823

Display your SmartForm.

Go to Environment and copy the function module name.

Go to SE37 and display the function.

Go to Smartforms and copy the node name where you want to debugg.

Go to the function and search for the name in main program. Put a soft break point.

Hope this helps.

Giridhar

Read only

Former Member
0 Likes
1,823

Hi

Method 1.

Goto SE37 and give the function module name of a Smartform.

Open the Function Module

Goto &#61664; Main Program &#61664;

It will display three includes:

First Include will have the Global Data Declaration.

Second Include will have the Form Interface.

Third Include will have the Main Program.

Open the third Include and set the Break-Point wherever necessary

Method2.

In same way we can do it through transaction SE80.

reward if useful

Read only

varma_narayana
Active Contributor
0 Likes
1,823

Hi..

Sorry see the Correction below..

For smartforms debugging you can do this.

1. Execute the smartform (execute button in SMARTFORMS transaction)

2. Take the generated function module and display it in SE80.

3.Find the smartforms Elements (text elements, windows, code lines, loops) in this and set Soft break points.

Correct name is SMARTFORM_TRACE. You have lots of options for adequate analysis

<b>Tcode – SFTRACE</b>

<b>reward if helpful</b>