View Single Post
  #2 (permalink)  
Old January 5th, 2011, 06:23 PM
shawnc1959 shawnc1959 is offline
Registered User
Join Date: Dec 2010
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts

I don't know if this might help (I haven't downloaded your XML), but I was running into a similar problem using code to create the options menu, where I was getting null returned from menu.findItem(REMOVE_TODO). I figured out that it was an error on my part in writing the code in onCreateOptionsMenu() when creating the remove menu item ... I had copied the previous line that creates the add menu item but in modifying the copy, I neglected to change 'ADD_NEW_TODO' to 'REMOVE_TODO', so I effectively created two menu items with the same ID (doh!). Which is why it couldn't find the right one in onPrepareOptionsMenu().

So perhaps you've done something similar in your XML (which is what I'm about to attempt myself).
Reply With Quote