View Single Post
  #27  
Old 4th October 2007, 06:35
Hitesh Shah's Avatar
Hitesh Shah Hitesh Shah is offline
Guru
 
Join Date: Nov 2001
Location: Mumbai,India
Posts: 1,683
Hitesh Shah is on a distinguished road
Baan: triton,Baan IVc4 , ERP Ln - DB: Oracle/Bisam/SQL 2000/SQL 2005 - OS: Sun Solaris/Windows 2003
get_enum_value

This is an excellent function found in standard program which shows the enum / set options on a field when called in before.zoom section of a field .
PHP Code:
function extern long get_enum_value(                                                     
 const 
string dom_name(),                                                                   
 
long type,                                                                                 
 
ref string descr())   

where dom_name set or enum domain
type 
db.enum or db.bitset 
descr 
enum description 

Return value is the database value of the selection 
If it is called before.zoom section of string field with appropriate arguments , attr.zoomcode is set to 0 in same section , it can give the impact of enum/set entry just like standard program .

One can use rdi functions like RDI.COLUMN, RDI.DOMAIN , RDI.DOMAIN.ENUM ,RDI.DOMAIN.ENUM.VALUE , RDI.DOMAIN.SET, RDI.DOMAIN.SET.VALUE along with enum functions like etol() ,ltoe() and enum.descr$() in important field sections (like beore.display , before.input , after.input , when.field.changes etc ) to get a same feeling of entering data in enum field itself and storing the same in backend database consistently .
Reply With Quote