Adding and removing childs - how to do it safe

Hello Kirupa Forum,

I got a problem with something, hope if someone know the awser.

I did a site navigation based on frames. When the site is on frame1, it addChild of a movieclip called ‘mc’. But when I go to frame 2, I dont need mc anymore, so I call removeChild to remove the undesired mc. But when I go from another frame and step in frame 2 again, the mc does no exist and the code halts on the removeChild line. Someone have a good idea?