{% Dim useList = (CurrentADC.PropValue("useList") = "true") ' Convert to boolean Dim inputName = CurrentQuestion.InputName() Dim inputValue = CurrentQuestion.InputValue() Dim imageAlign = CurrentADC.PropValue("imageAlign") Dim minValue = CurrentQuestion.MinValue Dim maxValue = CurrentQuestion.MaxValue Dim rangeLength = 0 Dim j Dim ar = CurrentQuestion.ParentLoop.Answers Dim caption Dim image Dim attrMin = On(minValue <> DK, "min=\"" + minValue + "\"", "") Dim attrMax = On(maxValue <> DK, "max=\"" + maxValue + "\"", "") Dim attrRequired = On(CurrentQuestion.IsAllowDK, "required=\"required\"", "") Dim unitStep = 1 Dim attrStep = On(unitStep > 1, "step=\"" + unitStep + "\"", "") If useList And minValue <> DK And maxValue <> DK Then rangeLength = (maxValue - minValue) / unitStep EndIf %} {% For j = 1 To ar.Count inputName = CurrentQuestion.Iteration(ar[j].Index).InputName() caption = ar[j].Caption image = ar.ResourceURL[j] %} {% Else %} {% EndIf %} {% Next %}
{% IF image <> "" And imageAlign = "left" Then %} {% EndIF %} {% IF image <> "" And imageAlign = "right" Then %} {% EndIF %} {% If rangeLength > 0 And rangeLength <= 20 Then Dim i Dim x = minValue %}