HI all, I would like to introduce a pb a met while creating an address book. Here is the pb: -> If I m in the contact list and select a contact A to see its informations, a new page opens and shows all contact A info. - Then I go back to the contact list, I select an other contact B - So a new contact info page should opened and retrive the contact B But the page is not re-created, so I still see contact A info
-> The solutions I tried: - All pages are created that way
So i try to destroy the page once I clik the "back" button and go back to the contact list. The page is well destroyed, but an error occured every time when I want to call it again.
- I tried also to reinit the elements Name, Mobile .. of the page before to leave it, but when I come back, the last state of the page is saved, and so i don't have the information of the contact B.
I don't have any more idea, that's why i came here to see if you had any suggestion. Thx [ April 12, 2006: Message edited by: white rabbit ]
Not seeing all of your code to have a good idea of it... the way I've done it in the past is just figured out where I'm coming into a given form, and ensure that however I'm hitting it, it's re-initializing the fields as necessary with the information. (In many cases, part of my jumping to a new display is to clear out all the fields and put in the information anew.) It sounds vaguely like you're hitting it someway that's keeping the old data.
But, if you give more information, I can try to help in a more meaningful way.
Theodore Jonathan Casser
SCJP/SCSNI/SCBCD/SCWCD/SCDJWS/SCMAD/SCEA/MCTS/MCPD... and so many more letters than you can shake a stick at!
Joined: Apr 10, 2006
i think i see what you mean, my problem is that, because the page has already been created one time (for the contact A), even if i destroy it when i don't need it, I can't create a new one for the contact B.
tomorrow i will show you the error message I get.
Thanks for your help
edit: i corrected the words. thanks [ April 13, 2006: Message edited by: Kim Prescott ]
Would you please spell out the words in your messages? we have many members for which English is not their primary language. Using abbreviations can make it much harder for them to follow what you are saying.
You may want to read this for more on why we prefer it this way.
There are only two hard things in computer science: cache invalidation, naming things, and off-by-one errors
Joined: Apr 10, 2006
ok my problem is solved.
in fact, when I destroyed the form, I forgot to destroy also all the object that are on this form.
so the second time when I called the form (contact info), the middlet tried to call the old object that were addressed with the old page and the middlet crashed.
All is fine now. thanks to people who tried to help me.