cancel
Showing results for 
Search instead for 
Did you mean: 

automatic preview

Former Member
0 Kudos

hello gurus!!!

im developing a smartform... and I want to display the preview of the smartform automatically before i print without displaying the "print dialog box".

what should i do, to eliminate the print dialog box?

may you please explain in details the steps to undetake.

i will give rewards. thanks

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi Levis,

We had a similar scenario...

Well here is the solution...

  • For ONLY PREVIEW

ST_CONTROL_PARAMETERS-NO_DIALOG = 'X'.

ST_CONTROL_PARAMETERS-PREVIEW = 'X'.

  • For PRINTING DIRECTLY

ST_CONTROL_PARAMETERS-PREVIEW = ' '.

ST_CONTROL_PARAMETERS-NO_DIALOG = 'X'.

ST_OUTPUT_OPTIONS-TDIMMED = 'X'.

CALL FUNCTION v_fm_name

EXPORTING

  • ARCHIVE_INDEX =

  • ARCHIVE_INDEX_TAB =

  • ARCHIVE_PARAMETERS =

CONTROL_PARAMETERS = st_control_parameters

  • MAIL_APPL_OBJ =

  • MAIL_RECIPIENT =

  • MAIL_SENDER =

OUTPUT_OPTIONS = st_output_options

  • USER_SETTINGS = 'X'

IMPORTING

DOCUMENT_OUTPUT_INFO = st_document_output_info

JOB_OUTPUT_INFO = st_job_output_info

JOB_OUTPUT_OPTIONS = st_job_output_options

TABLES

IS_LABELS = IS_LABELS

EXCEPTIONS

FORMATTING_ERROR = 1

INTERNAL_ERROR = 2

SEND_ERROR = 3

USER_CANCELED = 4

OTHERS = 5

.

IF SY-SUBRC <> 0.

MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO

WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.

ELSE.

Regards,

Fawaz

Former Member
0 Kudos

Thank you Fawaz. I got it.

Answers (0)