enumeration in if statement

0
Hi, entity with attribute enumeration agerange : with values young and old. and age (decimal) what is the if statement in create object to change age to 10 if agerange is young and age is 60 when agerange  is old  in tried:   if $member/agerange = young then 10 else 100 but get error mismatched input 'then'expecting '9'('   probably have ta add some ( ..  
asked
1 answers
1

if $member/agerange = modulename.enumerationname.young then $member/age = 10 else

if $member/agerange = modulename.enumerationname.old then $member/age = 60 else

$member/age

Assuming that you place these if statements in the commit of the member age attribute.

Regards,

Ronald

 

 

answered