Please ensure Javascript is enabled for purposes of website accessibility
Powered by Zoomin Software. For more details please contactZoomin

AVEVA™ Plant SCADA

ITrendCursor​.PenLabelVisible [Property][Get/Set]

ITrendCursor​.PenLabelVisible [Property][Get/Set]

  • Last UpdatedJul 18, 2023
  • 1 minute read

Get or Set the label visibility of the specified pen on this cursor.

Defined As

  • [VBA] Boolean PenLabelVisible(pen As Object)

  • [Cicode] INT PenLabelVisible(OBJECT pen)

  • [C++] HRESULT PenLabelVisible(IPen* pen, VARIANT_BOOL labelVisible)

Parameters

pen

[in] The pen for which cursor label is to be referenced.

Execution Result

If the property get/set succeeds, the return value will be Success. If the return variable is bad, the return value will be InvalidArgument. If the cursor is deleted, the return value will be GeneralFailure.

Limits

  • True (-1): Label is visible.

  • False (0): Label is hidden.

Remarks

Setting the visibility of the cursor using the Visible property will override the pen label visibility. For example, if a particular label is hidden using PenLabelVisible, this label will be shown again if Visible is set to True (-1).

Calling Syntax

This example assumes you have a valid reference to a cursor and a pen.

[VBA]

Sub Example(cursor As Object, pen As Object)
Dim labelVisible As Boolean
`Getting Property value
labelVisible = cursor.PenLabelVisible(pen)
`Setting Property value (False)
cursor.PenLabelVisible(pen) = False
End Sub

[Cicode]

FUNCTION Example(OBJECT hCursor, OBJECT hPen)
INT labelVisible;
// Getting current property value
labelVisible = _ObjectCallMethod(hCursor, "get_PenLabelVisible", hPen);
// Setting Property to FALSE
_ObjectCallMethod(hCursor , "put_PenLabelVisible", hPen, 0);
END

See Also

ITrendCursor.Visible [Property][Get/Set]

In This Topic
TitleResults for “How to create a CRG?”Also Available in