03-17-2010 01:53 AM
I am trying to implement listfield with checkboxes and i have seen its code in the knowledge base.
But i want that when i click on the checkbox it should be checked or unchecked only and give the index of the list row but no navigation click should occur and when i click on the rest part of the row, i.e. anywhere except the checkbox then navigation click should occur without checking the checkbox and it should display a new screen having the details of that list element.
How can i do that ?? Or i should do something else to do it.. Please suggest..
03-17-2010 05:32 AM
I presume you are doing this for a TouchScreen device only. The standard ListField on a normal ListField does not distinguish between parts of the displayed row, all the row has focus.
I suspect you have two options:
a) Extend ListField to support multiple focus positions on a single row, so that on touch screen devices when scrolling down the ListField you display a focus on the Check box or on the List Item. I have no idea how difficult this would be.
b) Change to use some sort of HorizontalFieldManager in pace of each of ListField rows, so that there are in fact two separate focusable areas.
I would not recommend the Manager Approach if you have many 100's of rows to display. If not, then it might be your best option. Search the forum for references to TableLayoutManager - you will find there is a KB article and a blog that demonstrates how to use it and I think it might help with what you want.
03-17-2010 06:34 AM
Thanx Peter. I Think i'll have to study TableLayoutManager because i want different foucuses on a single row.
Thanks for replying.. will get back to you if i find some problem..