I am using a basiceditfield to take input from the user to do some simple string search. But if i type a few letters and wish to go back without continuing the search, it automatically asks me whether to save the contents of the field. I don want this to happen. Can i in any way disable the "Changes made!-save-discard-cancel" option in basiceditfield(or any editfield for that matter)????please help!!!
+2
A:
Try adding this to your MainScreen class:
protected boolean onSavePrompt() {
return true;
}
Vivart
2010-03-17 10:30:51
worked!!! thanks a lot ...!!
chethan
2010-03-17 14:29:50
+1
A:
Another way would be to override the dirty state logic on your Screen class like this:
public boolean isDirty() { return false; }
Of course you can also just override that same method on a subclass of your Field, and that too should probably work. (assuming you still want to do dirty-state-tracking of other fields on the screen.)
octo
2010-03-17 12:54:51