cancel
Showing results for 
Search instead for 
Did you mean: 

How to assign a printer to a script form

Former Member
0 Kudos

Hi Experts,

can any one of you help me in expaling thsi with code elaboratly.

bcos i have seen some section scrren with requesting an output device.

but the end user is always using a transaction whre he can't give any printer name.

see below.

selection-screen begin of block aaa with frame title text-001.

select-options: so_lgnum for zle_binlblprint-lgnum, "whse

so_lgtyp for lagp-lgtyp.

parameters: p_ldest like itcpp-tddest.

parameters: p_formu like t329f-formu. "DEFAULT 'ZBINLABEL'.

parameters: p_prtqty(9) type n default 999999999.

parameters: p_arciv(13) type n default 7.

parameters: p_print like rldru-druck default 'X'.

selection-screen end of block aaa.

selection-screen begin of block xxx with frame title text-100.

parameters: p_tddel like itcpo-tddelete. "DEFATUL 'D'.

parameters: p_tdimm like itcpo-tdimmed default 'X'.

parameters: p_datas like itcpo-tddataset default 'BinLbl'.

parameters: p_copis like itcpo-tdcopies default '1'.

parameters: p_autor like itcpo-tdautority default sy-uname.

selection-screen end of block xxx.

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi sridhar

*To give the Number of copies required according to user input

w_itcpo-tdcopies = p_prntno.

*<b> To set the name of the output device to the default value

w_itcpo-tddest = ' '.</b> *

To set the name of the device type to the default value

w_itcpo-tdprinter = ' '.

*To delete the spool request immediately after printing

w_itcpo-tddelete = 'X'.

*To print the request immediately after completing it.

w_itcpo-tdimmed = 'X'.

*Name of spool request

w_itcpo-tddataset = 'NEW'.

*To create a new spool request

w_itcpo-tdnewid = 'X'.

*To enabe print preview

w_itcpo-tdpreview = 'X'

please reward points if helpful.

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi

For most of the output documents in SD and MM modules we assign the printer name in the COMMUNICATION METHODS in the respective application document

for example for a sales order in VA02 go to the Header outputs select the output type define the medium, partner, lang etc

and select that output tline and press the communication methods in menu

and define the Output device and the no of messages etc

this will automatically used while printing the output

<b>

Reward points for useful Answers</b>

Regards

Anji