Code: Select all
...
...
CTL_LST = [hvaSkjedde_ctl, mistenkt_skade_ctl,etiologi_ctl,skader_ctl,tiltak_ctl,rutiner_ctl],
foreach CTL = list::getMember_nd(CTL_LST) do
postAction({ :-
if CTL = skader_ctl,! then
CTL:insertText("ICD 10-diagnoser")
else
if CTL = etiologi_ctl,! then
CTL:insertText("Beskriv tilbakenforliggende fallmekanisme")
end if
else %error BEFORE 'else'
CTL:insertText("Beskriv")
end if %error BETWEEN 'end' and 'if'
CTL:selectAll(),
CTL:overType := true(),
CTL:wrapMode := sciLexer_native::sc_wrap_word
})
end foreach.
If I omit the second "else if-then-end if"-block, the code compiles.