I use the CreatBlock function for some FOR-Next loops to build screens. Now I want to use it to get the value of several get properties in a loop. However I don't get this to work. Any suggestions? Here is what I use now:
- Code: Select all Expand view
PUBLIC aGegevenTekst[0][2]
AADD(aGegevenTekst, {'bloemkleur', ''})
AADD(aGegevenTekst, {'kleur kelk', ''})
AADD(aGegevenTekst, {'kleur kroon', ''})
AADD(aGegevenTekst, {'bloeivorm', ''})
AADD(aGegevenTekst, {'bloeitijd', ''})
AADD(aGegevenTekst, {'hoogte', ''})
AADD(aGegevenTekst, {'hoogte na 10 jr', ''})
AADD(aGegevenTekst, {'hoogte na 25 jr', ''})
AADD(aGegevenTekst, {'hoogte blad', ''})
AADD(aGegevenTekst, {'hoogte bloem', ''})
AADD(aGegevenTekst, {'breedte', ''})
AADD(aGegevenTekst, {'groeiwijze', ''})
AADD(aGegevenTekst, {'blad/loof', ''})
nRowPaint := 325
nColumn := 0
FOR n = 1 TO 13
oGetName := 'oGetFilter' + ALLTRIM(STR(n))
cGetVar := aGegevenTekst[n,2]
@ nRowPaint, nColumn SAY oSay PROMPT aGegevenTekst[n,1] OF oFld:aDialogs[ 2 ] SIZE 100, 20
oSay:SetAlign( 1 )
@ nRowPaint, nColumn+105 GET &oGetName VAR cGetVar OF oFld:aDialogs[ 2 ] SIZE 200, 20
&oGetName:bChanged := CreateBlock( oGetName )
nRowPaint := nRowPaint - 25
NEXT
*************************************************
FUNCTION CreateBlock( cName )
RETURN { || RK_ChangeGegevenSelect( cName ) }
*************************************************
FUNCTION RK_ChangeGegevenSelect(cName)
LOCAL nGegeven := VAL(SUBSTR(cName, 11))
MsgInfo(cName)
aGegevenTekst[nGegeven,2] := cName:GetText
RETURN
Greetings,
René