Enable Email + Print with a Single Output Type

Use one output type to handle both email and hard-copy printing, without maintaining duplicate output types.

Configuration Steps

  1. Go to Output Maintenance (Tcode: NACE).
  2. Create a new Processing Routine by copying the standard routine.
  3. Modify the ENTRY routine to ENTRY_PRINT.
  4. Apply this enhancement only for Medium 5 (External Send) so that the system generates a hard-copy print in addition to the email output.

Advantages

  • No duplicate output types required.
    • A single output type can handle both email and print requirements.
  • Flexible control through variables.
    • Printing behavior can be controlled dynamically using a variable.
    • Example: Suffix2 = PRINT triggers additional hard-copy printing while retaining email functionality.
Result for Medium 5 output records
  • Email is sent as usual.
  • A hard-copy print is generated automatically.
  • No additional output type maintenance is required.
SAP output processing configuration screenshot
Output configuration reference

Print Program Enhancement

Requirement

Enable hard-copy printing in addition to email when using a single output type with Medium 5 (External Send).

Technical Design

  • Copy the existing routine ENTRY to a new routine ENTRY_PRINT.
  • Add logic to check whether SUFFIX2 = 'PRINT' is maintained (yellow-shaded field).
  • Only when SUFFIX2 = 'PRINT':
    • Reset output medium from '5' (External Send) to '1' (Print Output).
    • Execute the print process.
  • Otherwise, continue with the normal email process.

Sample Logic

ABAP · ENTRY_PRINT
***********************************************************************
* Additon Print after Email                                           *
***********************************************************************
* Start insert
FORM ENTRY_PRINT USING RETURN_CODE US_SCREEN.

  SELECT SINGLE vkorg fkart
    INTO (g_vkorg, g_fkart)
    FROM vbrk
    WHERE vbeln = nast-objky.

  check XSCREEN <> 'X'.      "not print preview

  If nast-DSUF2 = 'PRINT'.   "enable print when suffix2='PRINT'
    nast-nacha = '1'.        "Set to print-mode
    clear gv_email_enh_flag. "Clear email flag

    CLEAR RETCODE.
    clear V_HDP.
    XSCREEN = US_SCREEN.

    IF tnapr-fonam = 'INV'.
      g_copy1 = c_customer_copy.
      PERFORM processing USING us_screen.
*     g_copy1 = c_accounting_copy.
*     PERFORM processing USING us_screen.
      g_copy1 = c_credit_n_collection_copy.
      PERFORM processing USING us_screen.
    ELSE.
      PERFORM processing USING us_screen.
    ENDIF.
  endif.

  CASE RETCODE.
    WHEN 0.
      RETURN_CODE = 0.
    WHEN 3.
      RETURN_CODE = 3.
    WHEN OTHERS.
      RETURN_CODE = 1.
  ENDCASE.
ENDFORM.
* End insert

Process Flow

ConditionOutput MediumResult
SUFFIX2 blank5 (External Send)Email only
SUFFIX2 = PRINT5 → 1Hard-copy print generated
Other SUFFIX2 values5 (External Send)Email only

Benefits

  • Single output type for both Email and Print.
  • No duplicate output configuration in NACE.
  • Business users can control print behavior directly through SUFFIX2 = PRINT.
  • Easy to extend later for additional options (e.g., ARCHIVE, FAX, LOCAL_PRINT).

VV31 Output Condition Maintenance

To enable Email + Hard-copy Print using a single output type:

  1. In VV31, maintain the output condition with Medium = 5 (External Send).
  2. Set Suffix2 = 'PRINT'.
  3. The custom routine ENTRY_PRINT will detect SUFFIX2 = 'PRINT', switch the medium to 1 (Print Output), and generate an additional hard-copy print while preserving the email output.

Result

MediumSuffix2Output Result
5 (External Send)PRINTEmail + Hard-copy Print
5 (External Send)BlankEmail Only

Customer-Specific Exception

For customers who require email only (without hard-copy printing):

  • Maintain a separate condition record using a customer-specific key combination in VV31.
  • Keep Suffix2 blank.

This ensures:

  • Email is sent as normal.
  • No additional hard-copy print is generated.
  • No separate output type is required.
Summary
  • Suffix2 = PRINT → Email + Hard-copy Print.
  • Suffix2 = Blank → Email Only.
  • Controlled entirely through condition records in VV31, providing flexible customer-specific behavior without duplicating output types.
SAP VV31 output condition maintenance screenshot
VV31 condition maintenance reference