Touch screens usually render a "touch" as a click, so this probably
won't be difficult to implement.  Obviously you will want to develop
against an actual sample of the hardware.

 

On your swap, use getItemAt() to put a ref to each item into a temp var,
then use setItemAt() to replace the old items.  This will save a lot of
index issues over removing items.  I see three lines of code.

 

Tracy

 

________________________________

From: [email protected] [mailto:[EMAIL PROTECTED] On
Behalf Of Vivian Richard
Sent: Tuesday, August 05, 2008 4:29 PM
To: [email protected]
Subject: Re: [flexcoders] how to swap two rows in a datagrid

 

Thanks Tim and Tracy. I guess I need to make it little clear
as Tracy suggested. I want to select 2 rows and as I click
a button those 2 rows will take each other's place. Now one
more thing I want to do this in a TOUCHSCREEN monitor.
Now the problem is how do I select 2 rows in a datagrid
where there is no KEYBOARD?

On Tue, Aug 5, 2008 at 11:01 AM, Tracy Spratt <[EMAIL PROTECTED]
<mailto:tspratt%40lariatinc.com> > wrote:
> Do you really mean "swap"? Or just re-order, as in move one row to
another
> location? Resequence is pretty simple, swap is more complicated.
Either
> way, as Tom says use those Collection API methods. Be careful with the
row
> indexes, since removeItemAt will cause the indexes to change for any
row
> "above" it (below from an index standpoint)
>
>
>
> Tracy
>
>
>
> ________________________________
>
> From: [email protected] <mailto:flexcoders%40yahoogroups.com>
[mailto:[email protected] <mailto:flexcoders%40yahoogroups.com>
] On
> Behalf Of hworke
> Sent: Tuesday, August 05, 2008 11:50 AM
> To: [email protected] <mailto:flexcoders%40yahoogroups.com> 
> Subject: [flexcoders] how to swap two rows in a datagrid
>
>
>
> Hi,
>
> how can I swap two rows in a datagrid?
>
> 

 

Reply via email to