Oops, my bad. Below is the code for each of the two inline scripts:
'InitializeTrial' inlinescript:
'Designate "theSlide" as the current Slide
Dim theSlide As Slide
Set theSlide = VASSlide
'Designate "theState" as the Default Slide State, which is the
'current, ActiveState on theSlide
Dim theState as SlideState
Set theState = theSlide.States("Default")
'Gain access to the SlideCursor SlideText.
Dim Drag1 As SlideText
Set Drag1 = CSlideText(theState.Objects("SlideCursor"))
Drag1.X = "55%"
Dim theRating As SlideText
Set theRating = CSlideText(theState.Objects("Rating"))
theRating.X = "55%"
theRating.Text = ""
--------------------------
'ChangeScale' inline script:
Dim nCurrentScore As Integer
nCurrentScore = 25
Dim nResponseCount As Integer
Dim theKeyboardResponseData As KeyboardResponseData
Do While theSlide.InputMasks.IsPending()
'Was there a response?
If theSlide.InputMasks.Responses.Count > nResponseCount Then
nResponseCount = nResponseCount + 1
Set theKeyboardResponseData =
CKeyboardResponseData(theSlide.InputMasks.Responses(nResponseCount))
'Move cursor/change score
If theKeyboardResponseData.RESP = "{RIGHTARROW}" Then
'Check for top of scale
If nCurrentScore <= 49 Then
nCurrentScore = nCurrentScore + 1
Else
Debug.Print "top of scale"
End If
Else
'Check for bottom of scale
If nCurrentScore > 0 Then
nCurrentScore = nCurrentScore - 1
Else
Debug.Print "bottom of scale"
End If
End If
'Update the slider (adjusted by 5%) and rating feedback
Drag1.X = CInt(nCurrentScore * 2) -.8 & "%"
theRating.Text = nCurrentScore
theSlide.Draw
Sleep 1
End If
Loop
c.SetAttrib "Rating", nCurrentScore
--------
Thanks.