on 01-16-2008 8:02 AM
Hi gurus, pls help me ...
I had a program to print voucher. It show document list, and user can choose some document to print (smartform). Now, if I choose 5 document, I have to choose printer 5 times. Who can tell me the way to get default printer of the desktop which user's using to assign OUTPUT_OPTIONS or something like that!? Thanks for all.
hi,
Please refer the code elow..u should be able to crack this roblem..
data: l_usr01 like usr01.
CALL FUNCTION 'GET_PRINT_PARAM'
EXPORTING
I_BNAME = sy-uname
IMPORTING
E_USR01 = l_usr01.
output_options-TDARMOD = '1'.
output_options-TDDEST = l_usr01-spld.
output_options-TDRECEIVER = sy-uname.
output_options-TDCOPIES = '1'.
output_options-TDIMMED ='X'.
output_options-TDDELETE = 'X'.
output_options-TDLIFETIME = 0.
output_options-tdnoprev = 'X'.
output_options-tdnoprint = space.
output_options-tddelete = 'X'.
Please, assign points, if u have found it useful..
Thanks,
Nivin
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
U can set the default printer from SU01 -> defaults tab
u can select the printer and save the user.
If you want to handle it through program,
U have to define a structure of type SSFCOMPOP and send the parameter TDDEST as your output type lets say LP01
and then pass this structure to OUTPUT_OPTIONS of the smartform.U can pass other options like number of copies and print immidiately etc. and through CONTROL_OPTIONS
you can supress the dialog by setting NO_DIALOG = 'X'
and passing the structure SSFCTRLOP to CONTROL_OPTIONS.
Reward Points if useful.
Cheers,
Deepthee Kasal
Cheers,
Deepthee Kasal
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
Use this query and you will the default output device for the particular user.
SELECT SINGLE spld FROM USR01
into w_spld
where bname = sy-uname.
*Reward points if helpful
Regards,
KK
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
101 | |
13 | |
13 | |
11 | |
11 | |
7 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.