Call a function every time on Movie load

Hi everyone
I have a movieclip by name popup1. When I click on a button I am calling this movielcip using
popup1._visible=true;
I want that whenever I am calling this popup1, a function refresh should always be called. How can I do that?
Thanks