cancel
Showing results for 
Search instead for 
Did you mean: 

Print Immediately Option

Former Member
0 Kudos

In a SMARTFORM when we are trying to print it,

I want the Print Immediately option to be checked automatically.

Can someone tell me how to do that? Please help me with this............

Thanks

Archana.

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

when the print options dialog box pops up at the time of printing, check the chek box 'print immediately'.

if u want to handle it progmatically then do this:

data: v_SSFCOMPOP type SSFCOMPOP.

v_SSFCOMPOP-tdimmed = 'X'.

CALL FUNCTION v_form_fm

EXPORTING

p_compensation = p_comp <--parameter list

p_skill = p_skill

p_deci_auhtority = p_da

OUTPUT_OPTIONS = v_SSFCOMPOP

USER_SETTINGS = space

TABLES

s_job = s_job <--select option list

s_level = s_level

s_date = s_date

EXCEPTIONS

formatting_error = 1

internal_error = 2

send_error = 3

user_canceled = 4

OTHERS = 5.

Former Member
0 Kudos

What other parameters have to be populated into the structure?

Its not working.

Thanks,

Archana.

Former Member
0 Kudos

Hi,

In the structure of the control_parameters set:

device = 'LOCL'.

no_dialog = 'X'.

preview = space.

Regards,

Subramanian

Former Member
0 Kudos

Hi..

*Declare WA parameters and options for Printer Settings

Data: wa_parameters TYPE ssfctrlop,

wa_options TYPE ssfcompop.

*before calling SF

*if the printer name you getting from User Profile table then we *need not select it, then we use no_dialog parameter

w_parameters-no_dialog = 'X'. "if you do't want

w_parameters-preview = 'X'. "Preview

w_options-tdnoprint = 'X'. "No printing from print preview

w_options-tdnewid = 'X'. "New spool request

w_options-tddest = g_spld. "Printer name from User Profile *table

w_options-tdimmed = 'X'. " to check Print immediately

*then call SF

CALL FUNCTION g_fm_name

EXPORTING

control_parameters = w_parameters

output_options = w_options

user_settings = ' '

TABLES

tbl_pitem = tbl_xxx " Your tables

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.

ENDIF.

Regards,

sg

Former Member
0 Kudos

While calling the smartfrom (i.e. in the FM of the smartform), please set the value of the field TDIMMED (You can find this in the importing structure OUTPUT_OPTIONS) as 'X'.

Regards

Kathirvel