Sample - Field Property Strategy

Version 2

    Versions: 9.3.1 - current

    Product Availability: ArcFM Desktop

     

    Field property strategies allow users to set any of the following ArcFM field properties based on specific criteria: Visible, Editable, Allow NULL Values, Allow Mass Attribute Update, Reset After Create, and CU Defining (Designer only). These properties may be found on the Field Info tab of the ArcFM Properties Manager. Custom field property strategies use the IMMFieldProperty interface.

     

    How to Implement:

    1. You may modify the code sample. This step is not required.
    2. Build the solution.
    3. Copy the DLL to the ArcFM Solution\bin directory.


    How to Use:

    1. In ArcCatalog, right click a feature class and select the ArcFM Properties Manager.
    2. On the Field Info tab, select the the field to which you want to assign the custom field property strategy.
    3. Select the custom field property strategy from a property field: Visible, Editable, Allow NULL Values, Allow Mass Attribute Update, Reset After Create,     or CU Defining (Designer only).
    4. Click OK.


    Requires:

    All of the files shown below are required for the solution to build successfully.

     

    FileDescription
    Miner.Samples.FieldPropertyStrategy.csprojC# project containing the code to generate a custom field editor.
    FieldPropertyHelper.cs

    This class module provides methods used by the field property strategies. It checks a field for a phase value and whether the selected field belongs to a geodatabase row.

    Available in versions 10.0.1 - current.

    FieldPropFalse.csThis sample field property strategy sets the field to which it is assigned to False (e.g., Visible, Editable). This field property strategy appears in the drop-down menus with the following name: FieldPropertyFalse (.NET).
    FieldPropMaybe.cs

    This sample field property strategy randomly returns True or False to turn the field property to which it is assigned (e.g., Visible) on or off. This field property strategy appears in the drop-down menus with the following name: FieldPropertyMaybe (.NET).

    Available in versions 10.0.1 - current

    FieldPropTrue.cs

    This sample field property strategy sets the field to which it is assigned to True (e.g., Visible, Editable). This field property strategy appears in the drop-down menus with the following name: FieldPropertyTrue (.NET).

    Available in versions 10.0.1 - current

    VisPhaseA.cs

    This field property strategy reads the Phase Designation field (with the PHASEDESIGNATION field model name assigned) and returns a boolean value based on its phase value. If the value is A, this field property strategy returns True. Any other value returns False. This field property strategy appears in the drop-down menus with the following name: Phase A Visibility (.NET).

    Available in versions 10.0.1 - current

    VisPhaseB.cs

    This field property strategy reads the Phase Designation field (with the PHASEDESIGNATION field model name assigned) and returns a boolean value based on its phase value. If the value is B, this field property strategy returns True. Any other value returns False. This field property strategy appears in the drop-down menus with the following name: Phase B Visibility (.NET).

    Available in versions 10.0.1 - current

    VisPhaseC.cs

    This field property strategy reads the Phase Designation field (with the PHASEDESIGNATION field model name assigned) and returns a boolean value based on its phase value. If the value is C, this field property strategy returns True. Any other value returns False. This field property strategy appears in the drop-down menus with the following name: Phase C Visibility (.NET).

    Available in versions 10.0.1 - current