Find does not always work in Standalone"
katir at hindu.org
katir at hindu.org
Tue Dec 9 20:31:08 EST 2003
Okay, let me try to rephraze that rule: system and rev (official) dialogs return content in it but the button clicks or error in the result.
Well, choosing "Cancel" in a system dialog box would return dialogData...feedback on user selection is consider "error data" but "Cancel" is passed to "the result," not "it" for "answer printer"
So, if there is a "general rule" its not that which you propose.
It would be good to now what it is...
On Dec 1, 2003, at 3:11 PM, Richard Gaskin wrote:
Alex Rice wrote:
On Nov 30, 2003, at 12:46 PM, katir at hindu.org wrote:
This is either a bug, where for use of "answer printer" Rev should
pass the result to "it" or needs more documentation if the globally
expected engine behavior is for anything from the system to *not* be
in "it" but be passed via the result, which is also logical. Old time
xTalkers may take that for granted, newbies will stumble
As Ken confirmed, the solution is to check the result, not "it". I
think the docs reflect that.
As a relative new xtalker I have sometimes been confused when sometimes
"it" is called for, and sometimes "the result". Is there any general
rule to be aware of?
As a very general rule, "the result" is used for error info while "it"
contains data.
Are there other exceptions to this?
Set the dontUseQT property to true, and it should revert to using Windows
MediaPlayer which should play MP3's and MPEG files in a player object. Also
depends whether you want to play short embedded clips or full movies/sound
recordings from files.
I am using the find function to search through a stack... a simple ebook with two fields on each card. Sometimes the field called "text" has more text than fits and needs to be scrolled to read it all... when I am in the IDE, it works fine the first attempt to find, finds the text string and even if the field has to be scrolled, scrolls down and puts a box around the found text. Subsequently chosing "find Again" works... move to the next instance on another card and draws a box around the find text. But when i make a standalone (OSX) the behavior is odd, it will go to the card where the text is found, but not put a box aroudn it, then if I hig mcmd-G again, it finds that instance on the same card and puts a box aroudn it. (thus requiring two clicks to find each instance. But then when if finds the text in a field that has to be scrolled down to show the text, nothing happens. It goes to the card and then stops, does not scroll down and will not mve on to the next instance on another card. Any ideas? This is ported from a very old supercard stack and possibly there are superior strategies that I have overlooked. it seems that something is resetting the find command... unclear exactly what is happening.
the button menu has this script: pulldown menu:
##contents:
Find/F
Find Again/G
##script:
on menupick tItemChosen
switch tItemChosen
case "Find"
searchForIt
break
case "Find Again"
doFind
break
end switch
end menupick
the stackscript has two small handlers:
global gLastFind
on searchForIt
ask "Find:" with gLastFind
if it is empty then exit searchForIt
put it into gLastFind
doFind
end searchForIt
on DoFind
find string gLastFind
if the result is "Not Found" then
answer quote
More information about the use-livecode
mailing list