cancel
Showing results for 
Search instead for 
Did you mean: 

how to avoid a smartform from printing

Former Member
0 Kudos

Hi everybody

From a selection screen, a smartform is generated, whereby which before the generation, the standard print screen appears

but now the user wants after the selection screen, a list of the documents appear, with a 'Print' button, which will print all the documents, without the standard print screen appearing

Is it possible?

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

PREVIEW = space

NO_DIALOG = X

set these print parameters on dynamic FM call for smartform

Former Member
0 Kudos

the print screen is still appaering, followed by the smartform,

is there another setting?

former_member188685
Active Contributor
0 Kudos

pass space to the USER_SETTINGS

and for

OUTPUT_OPTIONS set the following

TDNOPREV = ' '.
TDDEST   = 'LP01' " <----Printer name
TDNEWID = 'X'. 
TDIMMED = ' '.

Former Member
0 Kudos

sorry for the misunderstanding but where I should put the settings you mentioned?

in CALL FUNCTION 'SSF_FUNCTION_MODULE_NAME' or CALL FUNCTION g_fm_name?

CALL FUNCTION 'SSF_FUNCTION_MODULE_NAME'

EXPORTING

formname = 'ZZDEBIT_NOTE'

IMPORTING

fm_name = g_fm_name.

  • For all the documents

LOOP AT gi_all_data INTO gw_all_data.

write: text-006, text-007, text-008.

  • Call the smarform

CALL FUNCTION g_fm_name

EXPORTING

gw_all_data = gw_all_data

PREVIEW = space

NO_DIALOG = 'X'.

Former Member
0 Kudos

Hi

set in this exporting parameter

wa_control- NO_DIALOG = X

WA_CONTROL-PREVIEW = SPACE.

CALL FUNCTION wf_fmname

EXPORTING

control_parameters = wa_control

Edited by: Lavanya K on Aug 25, 2008 4:36 PM

former_member188685
Active Contributor
0 Kudos

This is the samrtform general Interface. what ever i mentioned in my above post . you pass to the respecitve parameters.

USER_SETTINGS and OUTPUT_OPTIONS

*"*"Global Interface:
*"  IMPORTING
*"     VALUE(ARCHIVE_INDEX) TYPE  TOA_DARA OPTIONAL
*"     VALUE(ARCHIVE_INDEX_TAB) TYPE  TSFDARA OPTIONAL
*"     VALUE(ARCHIVE_PARAMETERS) TYPE  ARC_PARAMS OPTIONAL
*"     VALUE(CONTROL_PARAMETERS) TYPE  SSFCTRLOP OPTIONAL
*"     VALUE(MAIL_APPL_OBJ) TYPE  SWOTOBJID OPTIONAL
*"     VALUE(MAIL_RECIPIENT) TYPE  SWOTOBJID OPTIONAL
*"     VALUE(MAIL_SENDER) TYPE  SWOTOBJID OPTIONAL
*"     VALUE(OUTPUT_OPTIONS) TYPE  SSFCOMPOP OPTIONAL
*"     VALUE(USER_SETTINGS) TYPE  TDBOOL DEFAULT 'X'
*"  EXPORTING
*"     VALUE(DOCUMENT_OUTPUT_INFO) TYPE  SSFCRESPD
*"     VALUE(JOB_OUTPUT_INFO) TYPE  SSFCRESCL
*"     VALUE(JOB_OUTPUT_OPTIONS) TYPE  SSFCRESOP

Former Member
0 Kudos

its wat youve told to write, correct me if im wrong plz:

  • Get the function module name of the smartform.

CALL FUNCTION 'SSF_FUNCTION_MODULE_NAME'

EXPORTING

formname = 'zDEBIT_NOTE'

IMPORTING

fm_name = g_fm_name.

gw_options-tdnoprev = ' '.

gw_options-tddest = ' '.

gw_options-tdnewid = 'X'.

gw_options-tdimmed = 'X'.

  • For all the documents

LOOP AT gi_all_data INTO gw_all_data.

write: text-006, text-007, text-008.

  • Call the smarform

CALL FUNCTION g_fm_name

EXPORTING

gw_all_data = gw_all_data

user_settings = 'X'

output_options = gw_options.

ENDLOOP.

Former Member
0 Kudos

its still not working

Answers (0)