home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
PC Gamer 3.15
/
1998-06_Disc_3.15.iso
/
media
/
tech.dxr
/
00051_Text_51.txt
Wrap
Text File
|
1997-12-01
|
3KB
|
119 lines
--for moviescript
set the keydownscript to "checkKeys" --put this in on the moviescript
on checkKeys -- example 1
if the key = RETURN or the key = ENTER then
searchTitle
dontpassevent
else pass
end
on searchTitle
cursor 4
puppetSound (1) "pioolb"
global gTB
mSetCriteria(gTB, "appname", "Contains", field "searchFld")
mSelect(gTB)
set n = mSelectCount(gTB)
if (n <> 0) then
put n into field "NumberFound"
put mGetField(gTB, "appname") into field "appname"
put mGetField(gTB, "Contact") into field "contact"
put mGetField(gTB, "highs") into field "highs"
put mGetField(gTB, "lows") into field "lows"
put mGetField(gTB, "BottomLine") into field "BottomLine"
put mGetField(gTB, "Rating") into field "Rating"
put mGetField(gTB, "AlphSortKey") into field "AlphSortKey"
else
alert "No matching items were found."
end if
showselection()
go to "db2"
cursor -1
end searchTitle
-- for search window
on keyDown
checkKeys
end
--for db2
on keydown
cursor 4
global gAlpha
case (the key) of
"A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z": set i = (the key)
--This will change the char to uppercase if it is lowercase
if ( i >= "a" and i <= "z") then
set i = numToChar (charToNum(i) -32)
end if
put i into field "alphakey"
UpdateAlphaRT
end case
--THIS PART RESETS THE ARROWS
case (i) of
"A":set gAlpha to 1
"B":set gAlpha to 2
"C":set gAlpha to 3
"D":set gAlpha to 4
"E":set gAlpha to 5
"F":set gAlpha to 6
"G":set gAlpha to 7
"H":set gAlpha to 8
"I":set gAlpha to 9
"J":set gAlpha to 10
"K":set gAlpha to 11
"L":set gAlpha to 12
"M":set gAlpha to 13
"N":set gAlpha to 14
"O":set gAlpha to 15
"P":set gAlpha to 16
"Q":set gAlpha to 17
"R":set gAlpha to 18
"S":set gAlpha to 19
"T":set gAlpha to 20
"U":set gAlpha to 21
"V":set gAlpha to 22
"W":set gAlpha to 23
"X":set gAlpha to 24
"Y":set gAlpha to 25
"Z":set gAlpha to 26
end case
cursor -1
end
on UpdateAlphaRT
puppetSound (1) "pioolb"
global gTB
mSetCriteria(gTB, "AlphSortKey", "start", field "alphaKey")
mSelect(gTB)
set n = mSelectCount(gTB)
if (n <> 0) then
put n into field "NumberFound"
put mGetField(gTB, "appname") into field "appname"
put mGetField(gTB, "Contact") into field "contact"
put mGetField(gTB, "highs") into field "highs"
put mGetField(gTB, "lows") into field "lows"
put mGetField(gTB, "BottomLine") into field "BottomLine"
put mGetField(gTB, "Rating") into field "Ratings"
put mGetField(gTB, "AlphSortKey") into field "AlphSortKey"
put field "Ratings"&"%" into field "Rating"
else
CheckAlphaSearch
end if
showselection()
end UpdateAlphaRT
on CheckAlphaSearch
global gAlpha
set gAlpha=gAlpha+1
if gAlpha>26 then set gAlpha=1
put char gAlpha of field "alphaBet" into field "alphakey"
UpdateAlphaRT
end