Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!hellgate.utah.edu!cc.utah.edu!kofoid From: KOFOID@cc.utah.edu Newsgroups: comp.sys.mac.hypercard Subject: Re: Making areas of field text clickable Message-ID: <44336@cc.utah.edu> Date: 14 Feb 90 16:04:15 MDT Lines: 63 With regard to the recent question about double-clicking in field text: Place the following scripts into any field to make double-clickable buttons out of designated words. I've designed the scripts to key on "dill", "sweet" and "pickle", which should be mixed in with other words in the field to make the test complete. ========================================== on mouseUp wait 5 if the mouse is down then put the clickLoc into thePoint set the lockText of me to false click at thePoint click at thePoint if "on"&&(the selection)&return is in the script of me then send the selection to me else put "'"&(the selection)&"'"&&"is not a button." end if click at thePoint set the lockText of me to true end if end mouseUp on openField wait 5 if the mouse is down then click at the clickLoc click at the clickLoc if "on"&&(the selection)&return is in the script of me then send the selection to me put the result else put "'"&(the selection)&"'"&&"is not a button." end if end if end openField on pickle visual effect barn door close very slowly to black go to this cd end pickle on dill visual effect zoom close very slowly to gray go to this cd end dill on sweet visual effect dissolve very slowly to black go to this cd end sweet ===================================== Eric Kofoid Snail: Dept. Biology/U. Utah/S.L.C., Utah 84103 Good: bi.kofoid%science@utahcca Better: bi.kofoid@science.utah.edu Best: kofoid@bioscience.utah.edu