You are viewing an old version of this page. View the current version.

Compare with Current View Page History

Version 1 Next »

iDynamicPicklist Interface (PRIM_DC.IDynamicPicklist)
Interface that allows a reusable part to control the contents of a Dynamic Picklist used in a field visualisation
Ancestors - None

Details


The PRIM_DC.IDynamicPicklist is implemented by reusable parts acting as a Visual Host field visualization.
The Load method is executed whenever there is a need to load the picklist.

Example


This example uses the iDynamicPicklist interface to build a list of available departments.
Function Options(*DIRECT)
Begin_Com Role(*EXTENDS #PRIM_objt *implements #Prim_dc.IDynamicPicklist)
Mthroutine Name(Load) Options(*Redefine)
#Picklist.RemoveAll

  • Read the departments table and add a picklist for each record
    Select Fields(#Deptment #deptdesc) From_File(deptab)
  • Add the item using the department code and description. First item will become the default item
    #Picklist.Add( #Deptment ("&1 (&2)").substitute( #deptdesc #deptment ) #Picklist.Items.IsEmpty )
    Endselect
    Endroutine
    End_Com

    Methods

    Name

    Description

    Load

    Executed when the picklist needs to load Picklist

    See also

    All Component Classes
    Technical Reference
  • No labels