win.remove(view) does not remove view from screen?

You must Login before you can answer or comment on any questions.

Hi

I need to refresh a window with new information. The way I use is the check if a view is null, if so, remove it using

win.remove(view)

and then create a new view and add it to the windows by

win.add(newview)

However, on the screen, I see both the view and newview superimposed together... why is that so?

Thanks!

— asked 3 years ago by Peter Lum
0 Comments

5 Answers

If I understand your post correctly, you're checking to see whether a view is null, and if the view is null, you're attempting to remove the view?

I can't think of any circumstances in which a view that has been added to a window would become null.

Can you post an excerpt from your code?

Hello Peter, do you solve your problem? I've the same, how can you do that?

Thanks!

I'm also having this problem too :) If you could let me know it'd be GREATLY appreciated!

Thanks,

Peter

Found it, simply set object to null after removing it. I found the answer here: http://developer.appcelerator.com/question/125476/winremove-function-and-memory-management

Your Answer

Think you can help? Login to answer this question!