Get the record for an existing label from the repository.
Namespace: Perforce.P4Assembly: p4api.net (in p4api.net.dll) Version: 2017.3.160.836 (2017.3.160.0836)
Syntax
C# |
---|
public Label GetLabel( string label ) |
Visual Basic |
---|
Public Function GetLabel ( _ label As String _ ) As Label |
Visual C++ |
---|
public: Label^ GetLabel( String^ label ) |
Parameters
- label
- Type: System..::..String
Label name
Return Value
The Label object if label was found, null if creation failed
Examples
To get the admin_label:
CopyC#
![](../icons/CopyCode.gif)
string targetLabel = "admin_label"; Label l = rep.GetLabel(targetLabel);