Discussion:
Problem in table view handling
Abhijeet Singh
2011-06-09 10:29:53 UTC
Permalink
Hi,I have got a problem in my table view. There are four columns in my table view. The second column is editable rest are non editable. The last column has a button 'X' to delete the item. User can delete only the second last item from the table view. Hence 'X' button appears only corresponding to second last item in table view. The last item in table view is considered unsaved and it is by default always in edit mode and selected. It gets saved on Enter key press and a new unsaved item is added to the view. If user selects any row other than the last item (unsaved) rowin table view i remove the last unsaved item from the view (i do it in tableViewSelectionIsChanging). The table view can accommodate only 24 items after that scroll bar appears in the view.This scheme works perfect until there are less than (equal to) 24 items in the view. But when the items are more than 24 then scrollbar appears and then if I press 'X' button corresponding to second last item the click is not
sent to 'X' button action rather my selection change code (tableViewSelectionIsChanging) executes and removes the last unsaved item from the view. But on second attempt when i again click the 'X' button it works fine.I know the interface is bit complex and I am sorry if i couldn't describe it properly. Any help will be appreciated...Thanks & RegardsAbhijeetDear macosxdev ! Get Yourself a cool, short @in.com Email ID now!
Loading...