For example, in a card with one button and one editable field, if, in the button script:
Code: Select all
on mouseUp
focus on fld 1
end mouseUpCraig
Moderators: Klaus, FourthWorld, heatherlaine, kevinmiller, robinmiller
Code: Select all
on mouseUp
focus on fld 1
end mouseUpWell, it does something on 'nix in 9.5, when I run that from the message box, it briefly focuses the field before it ultimately focuses the tools palettedunbarx wrote: Fri Nov 01, 2019 5:59 pm But the same command from msg does nothing at all. Still that sort of behavior? LC 9.04

Code: Select all
hide msg; focus on fld 2 -- this worksIt could be, but I wasn't able to reproduce it on this box in 6 - 7.x versions of Lc, using 'focus on field 1' from the message box actually put the focus on the field but then returned it to the message box in those versions.[-hh] wrote: Fri Nov 01, 2019 10:48 pm @bogs. The repeated selection of the tools palette is an old unix bug.



Code: Select all
select after fld 1That has always worked. Msg seems to "get" more narrowly defined instructions, like "after", but "focus" is what I was asking about. This because the dictionary says quite clearly what this command should do to a field. Doing so from, say, a button script works just fine.select after fld 1

A button has no selectable text.dunbarx wrote: Sun Nov 03, 2019 1:21 amThat has always worked. Msg seems to "get" more narrowly defined instructions, like "after", but "focus" is what I was asking about. This because the dictionary says quite clearly what this command should do to a field. Doing so from, say, a button script works just fine.select after fld 1




Then the sensible thing might be to use 'that.'That has always worked.