Text (7,30) "Planner group" -intensified
DropDownList
(8,30) "ddl_plannergroups" width=40 refer="V[plannergroup]"

 

// Obtain dropdown list values from SAP customizing table
if
not text[ddl_plannergroups]

  // we select a particular plant, could be obtained from user parameters
    Set V[plant] "0006"

  // clear tables used in RFC call
 
Clear text[t1]
 
Clear text[t2]


    // read values from SAP table
    Call "/guixt/select" cache="session" in.TABLE="T024I" in.FIELDS="INGRP,INNAM" in.CONDITION="IWERK = '&V[plant]'" table.V1TABLE="t1" table.V2TABLE="t2"

    // put values into dropdownlist
    Set V[i] 1

 
label next_entry

   
CopyText fromText="t1" toString="f1" line="&V[i]"
    CopyText fromText="t2" toString="f2" line="&V[i]"

    if Q[ok]
      Set V[ddl_entry] "&V[f1]=&V[f1] &V[f2]"
 
CopyText toText="ddl_plannergroups" fromString="ddl_entry"
-appendlin
 
Set V[i] &V[i] + 1
    
goto next_entry
 
endif

endif
 

Performance hints