Harness proD API Help
EPLAN.Harness.API.Occurrences.Nailboard Namespace / OccNbSpiderDiagram Class / LegText1 Property
Example
In This Topic
    LegText1 Property (OccNbSpiderDiagram)
    In This Topic
    First text for a leg of this spider diagram. (The text before the colon.)
    Syntax
    public TextProperty LegText1 {get; set;}
    Exceptions
    ExceptionDescription
    Api is not in an initialized state. You can get current state from EPLAN.Harness.API.HpdApi.Status property. If API is uninitialized, you can initialize it by calling EPLAN.Harness.API.HpdApi.Init method. If API is in failed state, you can not resurrect it.
    The object is in invalid state. Obtain a new one.
    The exception that is thrown when you trying to access to already deleted occurrence.
    Argument is invalid. The exception is thrown when a wrong argument is passed to the method or the setter of property.
    Remarks
    The text for any leg of the spider diagram consist of: 'LegText1' : 'LegText2'.
    Example
    This example shows how to set LegText1 to any value.
    OccCdSpiderDiagram spiderDiagram = ...
    
    // Get all the possible properties.
    List<string> names = spiderDiagram.GetPossibleLegTexts();
    
    // Select your favorite property.
    string name = names.FirstOrDefault(n => n == "Document");
    
    spiderDiagram.LegText1 = new TextProperty(name);
    This example shows how to set LegText1 to any value.
    OccCdSpiderDiagram spiderDiagram = ...
    
    spiderDiagram.LegText1 = spiderDiagram.GetPossibleLegTexts().FirstOrDefault(n => n == "Project");
    This example shows how to set LegText1 to not show any value.
    OccCdSpiderDiagram spiderDiagram = ...
    
    spiderDiagram.LegText1 = new TextProperty(null);
    
    // Or just:
    // spiderDiagram.LegText1 = null;
    See Also