cancel
Showing results for 
Search instead for 
Did you mean: 

can any one tell me How can I handle internal error in smartforn

Former Member
0 Kudos

Hi,

How can I handle internal error in smartforn, what type of problem can be.

Regards

chandra

Accepted Solutions (0)

Answers (2)

Answers (2)

raymond_giuseppi
Active Contributor
0 Kudos

Look at [SAP Smart Forms (BC-SRV-SCR)|http://help.sap.com/printdocu/core/Print46c/en/data/pdf/BCSRVSCRSF/BCSRVSCRSF.pdf]

Runtime Errors

Each Smart Form can trigger a number of exceptions during its execution. To limit this number of exceptions, you can bundle the occurring errors in error classes and store them in an error log in the composer. For each error, you store an internal error number and (if possible) a message from table T100 (work area, message number, message text and parameters) in addition to the error class. To each error class, you assign an exception, which means that if the recognized error teminates the form processing, the system triggers exactly this exception. When an exception occurs, the caller of the Smart Form can use predefined function modules to read the error log and then decide which reaction is appropriate in the respective error context.

Possible exceptions for the generated function module are:

- FORMATTING_ERROR

- INTERNAL_ ERROR

- SEND_ERROR

- USER_CANCELED

In addition, you can define your own exceptions.

If an error (or a warning) occurs, the system internally fills an error table. The application can now read this table as soon as the function module for the form is processed to the end. To read the table that contains all errors and warnings that occurred, call function module SSF_READ_ERRORS. The table has structure SSFERROR. The fields in the table are the number of the document within the job, the form name, an error number, a message class, a message type, a message number and four additional message variables. If processing is terminated, the application can dynamically display a message. The error numbers are defined in the include SSF_ERROR.

If you want to trigger your own exception in the free coding of the Smart Form, you can use one of the following methods:

- Use the macro user_exception <exception>, which triggers the exception <exception> and fills the above tables. After the termination additional system variables for the error (symsgno, sy-msgtyp, and so on) do not contain the values required for your own exception.

- If you want to access the system variables sy-msgno, sy-msgtyp, and so on for your exception directly, proceed as follows: Call function module SSF_MESSAGE and trigger your exception yourself using the RAISE statement.

The system field &SFSY-EXCEPTION& contains the name of the triggered exception.

Then debug your program.

Regards

Former Member
0 Kudos

Hi,

Please put break point the FM:SSFRT_WRITE_ERROR at

append l_error to errortab.

and check ERRORTAB table.

Regards

Jana

Former Member
0 Kudos

How can I fixed that problem.

Regards

chandra

Former Member
0 Kudos

Hi,

Please check that errortab is populating any error message, Usually it gives template names and table window names.

Please adjust sizes for that.

Regards

Jana