Print a trend chart from a button using the invoke command

Operators can print a trend chart at runtime by right-clicking the trend chart and then selecting
Print Trend
. However, you can also provide a button on the
FactoryTalk View
display that prints the trend chart.
Use the PrintControl method to print the current trend runtime chart, along with its accompanying line legend and current value legend. If the chart includes a white pen, it temporarily changes to black for printing.
To print a trend chart from a button using the invoke command:
  1. Add a button to a graphic display, and click the
    Action
    tab.
  2. Click the browse button next to the
    Release Action
    box.
  3. In the right pane of the Command Wizard, click
    Invoke
    , and then click
    Next
    .
  4. From the
    Display
    list, select the name of the graphic display where the trend is.
  5. In the
    Object
    box, type the name of the trend (the default name is
    trend1
    ).
  6. In the
    Property
    or
    Method
    box, type
    PrintChart
    .
  7. In the
    Method Parameters
    box, identify the page orientation (landscape = 0, portrait = 1), and then identify the printer (print to default printer = 0, open print dialog and allow selecting a printer = 1).
    For example, to print a chart in portrait mode directly to the default printer, type: 1,0.
  8. Click
    Invoke method in object
    .
  9. Click
    Finish
    .
  10. Click
    OK
    to close the
    Button Properties
    window.
Provide Feedback
Have questions or feedback about this documentation? Please submit your feedback here.
Normal