I'm trying to save the variables of an iolist as a property with a dynamic approach. The purpose is to retrieve extermal parameters only once without the need to adjust anything when new parameters are introduced. So far I had no luck.
Here ist my class
def class "GetIOL" create required
property params$
function whatParams()
print "whatParams()"
print lst(iol(params$))
print sub(params$,sep,"~")
print params.name$
return 1
function end
end def
ON_CREATE:
call "GetIOL.pvc;FETCH_PARAMS", params$
print "ON_CREATE"
print lst(iol(params$))
print sub(params$,sep,"~")
print params.name$
return
FETCH_PARAMS:
enter p$
dim p$:iolist id$,name$,value
p.id$="ABC"
p.name$="XYZ"
p.value=42
exit
No variable arrives inside the object, though the iolist is constantly present.
I also tried static iol=iol(params$) and several other approaches. But everything failed.
This is my test program
begin
g=new("GetIOL")
g'whatParams()
delete object g
end
All suggestions are welcome.