You will probably have to get the Enter key event by listening for it in
"capture" phase and calling stopImmediatePropagation.

 

You might be able to do it by watching for ITEM_EDIT_BEGINNING and
intercept where it wants to move the editor.

 

________________________________

From: [email protected] [mailto:[EMAIL PROTECTED] On
Behalf Of Lex
Sent: Tuesday, March 13, 2007 3:11 PM
To: [email protected]
Subject: Re: [flexcoders] DataGrid! mx:Validator in a mx:DataGrid, and
Annoying "Enter" key behavior?

 

I did find this, that's good:

http://livedocs.adobe.com/flex/201/html/wwhelp/wwhimpl/common/html/wwhel
p.htm?context=LiveDocs_Book_Parts&file=celleditor_073_17.html
<http://livedocs.adobe.com/flex/201/html/wwhelp/wwhimpl/common/html/wwhe
lp.htm?context=LiveDocs_Book_Parts&file=celleditor_073_17.html> 

 

Still pending on the enter key business.

 

A.

 

        ----- Original Message ----- 

        From: Lex <mailto:[EMAIL PROTECTED]>  

        To: [email protected]
<mailto:[email protected]>  

        Sent: Tuesday, March 13, 2007 6:05 PM

        Subject: [flexcoders] DataGrid! mx:Validator in a mx:DataGrid,
and Annoying "Enter" key behavior?

         

        Hi.

         

            I'm looking to validate some input!  How precisely do I go
about connecting a Validator, perhaps a CurrencyValidator, to a
datagridcolumn?  The example at
http://livedocs.adobe.com/flex/201/langref/index.html
<http://livedocs.adobe.com/flex/201/langref/index.html>  is not cluing
me in.. >_<

         

         

            Also, when I click in a DataGrid square, the cell goes into
Edit mode, this is fantastic.  Intuitively, when I'm done, I hit the
'Enter' key.  This does complete the edit, unfortunately, it also opens
up an editor on the cell directly below the current - this is a behavior
I'd like to stop.  How can I override the 'Enter' key behavior on the
datagrid, such that it just stops editing the current cell?

         

        Thanks as always.

        Alex

         

         

 

Reply via email to