Bprati,
I can't see how that would work. You are saying you create eight pages in the form designer, but set the page count to 1 in the Init? Later, you increase the page count. You also have code in the each page's Activate event, which you presumably add at design time?
If I've understood it right, by setting the page count to 1, you are destroying pages 2 - 8 that you created at design time. You are also destroying the code in those pages' Activate event. When you later increase the page count, you will be creating
new pages, without the code. So the Refreshes won't fire, and you won't see the new page.
In VFP 8.0, you can solve that problem by creating a page class, and setting the member class of the pageframe to point to it.
I'm not sure what to suggest if you are using an earlier version. Maybe hide the tabs, and provide some other control for letting the user move between tabs. That way, you won't have to change the page count -- just don't let the user go to the pages that you want to hide.
Mike
Mike Lewis
Edinburgh, Scotland