on 07-25-2007 4:31 AM
Hi gurus,
Please tell me how to send the form to spool instead of printer?
Points are rewarded for useful answers.
Please let me know at the earliest.
regards
RAj.
In OPEN_FORM you will see a parameter called DIALOG,
The parameter DIALOG can be used to control whether a dialog box appears before output to the printer. The user can set various spool parameters for the output in this window.
Regards,
Sairam
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
How can we set same for smartforms
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You can use option in smartform:
DATA: p_out LIKE ssfcompop,
p_ctrl LIKE ssfctrlop.
CLEAR: p_out,
p_ctrl.
p_out-tdnoprev = 'X'.
p_out-tdnoprint = 'X'.
p_out-tdnoarch = 'X'.
p_out-tddelete = 'X'.
p_out-tddest = p_dest.
p_out-tdnewid = ''.
p_out-tdimmed = ' '.
p_out-tdcopies = 1.
p_out-tddataset = sy-repid.
p_out-tddelete = ' '.
CALL FUNCTION fm_name
EXPORTING
inv_header = tmp_header
<b>output_options = p_out
control_parameters = p_ctrl</b>
user_settings = ' '
TABLES
t_item = tmp_item
t_price = tmp_price
t_partner = tmp_partner
t_docflow = tmp_docflow
t_beer_item = tmp_beer_item
t_wine_item = tmp_wine_item.
Thanks
Seshu
See the below simple program and it creates spool ,use SP01 Transaction to see output.
&----
*& Report ZTESTSPOOL
*&
&----
*&
*&
&----
REPORT ztestspool.
DATA : arc_params TYPE arc_params,
v_print_parms TYPE pri_params,
w_valid TYPE char1,
w_valid_spool TYPE char1.
CONSTANTS : lc_paart LIKE sy-paart VALUE 'X_65_132', " Paper Format
lc_locl TYPE sypdest VALUE 'LOCL', " Destination
c_x TYPE char1 VALUE 'X'.
Setup the Print Parmaters
CALL FUNCTION 'GET_PRINT_PARAMETERS'
EXPORTING
authority = space
immediately = space
new_list_id = c_x
no_dialog = c_x
user = sy-uname
IMPORTING
out_parameters = v_print_parms
EXCEPTIONS
archive_info_not_found = 1
invalid_print_params = 2
invalid_archive_params = 3
OTHERS = 4.
IF sy-subrc NE 0.
CLEAR : v_print_parms.
ENDIF.
The printer destination has to be set up
IF v_print_parms-pdest = space.
v_print_parms-pdest = lc_locl.
ENDIF.
Explicitly set line width, and output format so that
the PDF conversion comes out OK
*v_print_parms-linsz = c_linsz.
v_print_parms-paart = lc_paart.
NEW-PAGE PRINT ON PARAMETERS v_print_parms NO DIALOG.
*PERFORM display_output.
write 😕 'This is test for spool generation'.
NEW-PAGE PRINT OFF.
*write 😕 'This is test for spool generation', sy-SPONO.
Thanks
Seshu
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
89 | |
10 | |
9 | |
9 | |
9 | |
6 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.