Printing the WinCC Runtime Workspace Only - Excluding Header and Button Bars in SIMATIC PCS 7 Hardcopies

Printing the WinCC Runtime Workspace Only - Excluding Header and Button Bars in SIMATIC PCS 7 Hardcopies

To print only the active plant workspace (the central process mimic) in SIMATIC PCS 7 WinCC Runtime without capturing the top overview area (@overview1.pdl), alarm line, and bottom button bars (@buttons11.pdl), utilize a targeted print job or picture window capture script rather than the generic full-screen HardCopy() function. In PCS 7 OS screen architectures, the central graphic is hosted within a dedicated picture window (typically named @Area or @Screen in @1001.pdl). By configuring a WinCC Report Designer layout containing a dynamic picture object linked to @CURRENT_PICTURE or calling the Siemens workspace hardcopy script (PRT_SCR.EXE with window coordinates), the OS prints exclusively the active process graphic.

Table of Contents

PCS 7 Split Screen Architecture: Overview, Workspace, and Button Bars

In SIMATIC PCS 7 OS Runtime, operator visual layouts are governed by the Split Screen Manager (SSM). Standard PCS 7 runtime pictures do not consist of a single monolithic screen file; rather, the desktop monitor (e.g., 1920x1080 resolution) is partitioned into three distinct functional zones defined in the master container @1001.pdl:

  1. Top Overview Area (@overview1.pdl): Displays the central plant alarm banner, date/time, active plant area breadcrumbs, and system status indicators.

  2. Central Workspace (@Screen / @Area Picture Window): The dynamic process graphic displaying reactors, columns, pipework, and interactive block icons.

  3. Bottom Button Bar Area (@buttons11.pdl, @buttons12.pdl): Displays navigation keys, faceplate call keys, alarm acknowledge buttons, and system utility buttons.

When operators or validation personnel request a hardcopy printout of a process screen, they typically require documentation of the technological process mimic only. Capturing the entire monitor wastes printer toner on dark system banners and shrinks the technological diagram, rendering text illegible.

Why the Standard HardCopy() Function Prints the Entire Desktop

The default hardcopy button on the standard PCS 7 button bar (@buttons11.pdl) calls the WinCC internal C-function:

HardCopy("WinCC-Runtime - ");

This function invokes the Windows print driver utility (PRT_SCR.EXE), which captures the entire top-level Windows application handle identified by the window title string. Because @overview1.pdl, the workspace window, and the button bar are all hosted within the same top-level WinCC runtime window, HardCopy() grabs the full screen buffer. It possesses no native awareness of internal WinCC picture window boundaries.

Implementing Targeted Workspace Printing via WinCC Report Designer

The cleanest, most robust PCS 7 solution leverages WinCC Report Designer and the PCS 7 Print Job architecture:

  • Dynamic Picture Layout: Create a page layout (*.rpl) in WinCC Report Designer with page margins configured for standard Letter or A4 orientation.

  • Dynamic Picture Object: Insert a dynamic picture object into the layout body. Configure its picture source property to point to the internal WinCC tag @CURRENT_PICTURE or read the active picture name from the @Area picture window.

  • Print Job: Create a print job in WinCC Explorer that links this page layout to the default plant network printer.

  • Operator Button: Attach a simple script to a button or hotkey that triggers this print job (ReportJobName). When invoked, the reporting engine opens the active workspace PDL directly and renders it at full vector resolution to the printer, completely bypassing the overview and button bar frames.

Scripting Targeted Picture Printing via C-Script and Windows API

For installations requiring an instant bitmap screengrab of the workspace without using Report Designer, engineers can deploy the Siemens application script described in FAQ 840776. This script uses Windows API functions to isolate the workspace handle:

  1. Call FindWindow() to locate the main WinCC runtime window.
  2. Call FindWindowEx() recursively to locate the child window handle corresponding to the @Screen or @Area picture window.
  3. Query the window dimensions via GetClientRect().
  4. Invoke PRT_SCR.EXE passing command-line parameters specifying the exact rectangular coordinates (left, top, width, height) of the workspace window, printing exclusively the process mimic.

Comparative Methodology Matrix: WinCC Hardcopy vs Targeted Printing

The following table compares different screen capture and printing techniques in SIMATIC PCS 7 WinCC Runtime:

Printing TechniqueExcludes Banners?Vector Resolution?Scripting OverheadExecution SpeedMaintenance ImpactStandard HardCopy()No (Full Screen Captured)No (Raster Bitmap)Zero (Built-in)ImmediateNoneReport Designer (@CURRENT_PICTURE)Yes (Workspace Only)Yes (High-Quality Vector)Low (Layout Configuration)2–5 SecondsRobust Across PCS 7 UpgradesWindows API Coordinate ScriptYes (Workspace Only)No (Raster Screen Bitmap)High (C-Script API Calls)ImmediateCoordinate Recalibration Needed on ResizingThird-Party Screen GrabberDepends on ToolNo (Raster Screen Bitmap)High (External App Integration)VariableSecurity / OS Compatibility Concerns

Step-by-Step Procedure to Configure Workspace-Only Printing

Follow this procedure to configure workspace-only printing using WinCC Report Designer:

  1. Create Page Layout in Report Designer:
    - In WinCC Explorer, expand Report Designer > Page Layouts.
    - Right-click and create a new layout named Workspace_Print.rpl.
    - Open the layout editor, set orientation to Landscape, and delete standard page header/footer bars.
    - From the object palette, drag a Picture of the active picture window object into the page body, filling the printable canvas.

  2. Configure Print Job:
    - In WinCC Explorer, expand Report Designer > Print Jobs.
    - Create a new print job named @Workspace_Print_Job.
    - In its properties, assign Workspace_Print.rpl as the layout file.
    - Set the output destination to the designated network laser printer or PDF export driver.

  3. Add Print Button to Button Bar or Screen:
    - In WinCC Graphics Designer, open @buttons12.pdl (or your custom navigation picture).
    - Add a button with a printer icon.
    - Under Events -> Mouse -> Mouse Click, insert the C-action:
    c #include "apdefap.h" void OnClick(char* lpszPictureName, char* lpszObjectName, char* lpszPropertyName) { RPTJobPrint("@Workspace_Print_Job"); }

  4. Deploy and Test:
    - Save the picture and deploy to OS Servers and Clients.
    - Activate Runtime, navigate to a complex process graphic, and click the print button.

Verification

Verify workspace printing functionality through these validation steps:

  1. Open WinCC OS Runtime and navigate to an active plant area mimic (e.g., Reactor Section).
  2. Click the configured Workspace Print button.
  3. Collect the printed document (or open the generated PDF file).
  4. Confirm that the top alarm overview banner (@overview1.pdl) is completely absent from the printout.
  5. Confirm that the bottom button bar (@buttons11.pdl) is completely absent.
  6. Verify that all process lines, vessel symbols, and dynamic block icon values within the workspace are sharp, clearly legible, and correctly rendered.

Limitations and Operational Precautions

  • Dynamic Picture Window Depth: If your process picture contains embedded picture windows (sub-windows or popups), Report Designer prints the base workspace PDL. Embedded pop-up windows may not be captured unless captured via raster coordinate printing.
  • OS Project Editor Template Updates: If you modify @buttons11.pdl or @buttons12.pdl, running the OS Project Editor can overwrite these files unless you protect them or place the print trigger on custom process screens.
  • Printer Driver Spooling: Ensure the print spooler service is active on the OS station. Heavy vector graphic printing on low-memory clients can momentarily cause CPU spikes.

Engineer FAQ

Can I export the workspace directly to a PDF file instead of a physical printer?

Yes. In the Print Job properties, select Microsoft Print to PDF, Adobe PDF, or a generic PostScript/PDF printer driver as the output device. Configure an automated output directory to save PDF snapshots.

Why is the printout background black when my screen background is gray?

This occurs if the WinCC color palette or printer driver color inversion is active. In Report Designer layout properties, check the option 'Print monochrome' or configure color mapping to ensure high-contrast white backgrounds.

Does printing the workspace freeze the operator screen while spooling?

No. RPTJobPrint() runs as an asynchronous background thread within the WinCC reporting subsystem and does not freeze the operator's GUI.

Where is the Siemens FAQ 840776 script located?

Siemens Industry Online Support entry 840776 provides downloadable C-scripts and PDFs (*_Arbeitsbereich.pdf) detailing coordinate-based workspace captures for WinCC classic and PCS 7.

Can WebNavigator clients print the workspace only?

WebNavigator clients do not have access to local server print jobs. However, operators can use the browser's native print function or dedicated WebNavigator export scripts.

Technical References

Related Articles

Related Tags

  • WinCC Printing
  • Hardcopy
  • Report Designer
  • Workspace
  • Split Screen Manager
  • PCS 7 OS
  • Graphics Designer
6 respuestas