on 05-07-2010 4:49 AM
Hi,
When i'm printing Work Order (trx: IW32) programs picks up default printer assigned to the user.
in my case this also happening when user selects different printer though dilog.
was trying to get it from NAST-LDEST but in my case NAST is empty and ITCPO pointing to LP01(Local Printer of user).
can anyone please help how to get printer name which is selected by user.
Thanks in advance,
Kian
Hi,
Below code show you the way to assign any printer to form. (Pls find the code in you print prog )
DATA: output_options TYPE ssfcompop.
DATA: control_parameters TYPE ssfctrlop.
output_options-tdimmed = 'X'.
output_options-tddest = 'PR01'. --- > here we can hard code the printer name and pass to FM
control_parameters-no_dialog = 'X'.
CALL FUNCTION fm_name
EXPORTING
control_parameters = control_parameters
output_options = output_options
user_settings = ''
nota_fiscal = i_nota_fis
EXCEPTIONS
formatting_error = 1
internal_error = 2
send_error = 3
user_canceled = 4
OTHERS = 5.
IF sy-subrc <> 0.
ENDIF.
As you need to know form where the value of output_options-tddest is coming then you can debug the flow and try to find the value of output_options-tddest ...
Pls tell me if you need to know anything else.
Regs,
Lokesh.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
Using smartform or Sap script? and if yes then are u using customized print program?
Regs,
Lokesh.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
95 | |
11 | |
11 | |
10 | |
9 | |
8 | |
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.