home *** CD-ROM | disk | FTP | other *** search
- on REFA2ZUpdateSection
- global REFNumDataRecords, ffXobj, openFile, DBCount, REFWordList, REFA2ZSPriteInfo, REFActiveSection, IFLButtonList, IFLReferenceNameSprite, REFSearchActive, REFWords, REFLastActive
- if rollOver(33) and the mouseDown then
- if DBCount < REFNumDataRecords then
- set DBCount to DBCount + 1
- end if
- REFFillWordBox()
- repeat while the mouseDown
- end repeat
- end if
- if rollOver(32) and the mouseDown then
- if DBCount > 1 then
- set DBCount to DBCount - 1
- end if
- REFFillWordBox()
- repeat while the mouseDown
- end repeat
- end if
- if rollOver(34) and the mouseDown then
- set the editableText of sprite 35 to 0
- REFCloseDatabase()
- REFClearSectionSprites()
- REFOriginalStage()
- set REFActiveSection to 0
- end if
- end
-
- on SearchWord
- global REFSearchWord, ffXobj, REFWords, DBCount
- if the key = RETURN then
- dontPassEvent()
- set REFSearchWord to EMPTY
- repeat with g = 1 to count(REFWords)
- put getAt(getAt(REFWords, g), 1)
- if getAt(getAt(REFWords, g), 1) = field "WordSearch" then
- set DBCount to g
- put DBCount
- REFFillWordBox()
- exit repeat
- next repeat
- end if
- if (g = count(REFWords)) and (getAt(getAt(REFWords, g), 1) <> field "WordSearch") then
- beep()
- dontPassEvent()
- put "'" & field "WordSearch" & "'" & RETURN & "not found" into field "WordNotFound"
- set the locV of sprite 36 to 200
- updateStage()
- startTimer()
- repeat while the timer < (3 * 60)
- end repeat
- set the locV of sprite 36 to 2000
- updateStage()
- end if
- end repeat
- put EMPTY into field "WordSearch"
- end if
- end
-