OpenField/ExitField Handlers in Datagrid?
lists at mangomultimedia.com
Mon Feb 28 07:32:34 EST 2011
On Sun, Feb 27, 2011 at 3:08 PM, RevList <RevList at createchsol.com> wrote:
> I am building an app and want to control the enabling and disabling of
> menu items based on where the cursor is. Mostly, I have no problem,
> except when I am in a datagrid.
> I have a datagrid that has only one editable column. When I double click
> on that column on a row and get into that specific field for editing, I
> want to enable some menu items (like Copy, paste). When I exit that
> field, I want to disable them.
> On other fields in the card, I do this on the OpenField and ExitField
> How do I do this in a Datagrid?
Might I suggest another approach? When the user clicks on a menu in your
menubar a mouseDown message will be sent to the menubar group. In that
mouseDown message Why not just use the selectedField and selectedChunk to
determine if menus that target text should be enabled/disabled? This puts
all of the checks in one place. The checks are really fast and won't cause a
delay in the menu being shown to the user.
Blue Mango Learning Systems
LiveCode Resources for Developers: http://livecode.bluemangolearning.com
More information about the Use-livecode