Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How to sub class a page
Message
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00902291
Message ID:
00903085
Views:
27
Hi Fred.

Thank you for yout very infomative ideas on MemberClasses.
I'll paly around with them.

Regards,
Gerard





>Several ways. For one way, you can create your own custom page class that has code in it's Activate event, or has a certain set of controls on it. Now, you can create a form, drop a pageframe class on it, and change the Pageframe.MemberClass and .MemberClassLibrary properties to point to your custom page class. Anytime you change the .PageCount property of the PageFrame, your custom pageclass will be used with instead of the base VFP Page class.
>
>If you have several different custom page classes that you'd like to use on the same page frame, you can deal with that programtically. Say you need the first to pages to be your TypeAPage, and the next 3 to be TypeBPage, and the last one to be TypeCPage, you could do it this way in the PageFrame.Init code:
>
>this.PageCount = 0
>this.MemberClass = "TypeAPage"
>this.MemberClassLibrary = "libraries\MyPages.vcx"
>this.PageCount = 2
>this.MemberClass = "TypeBPage"
>this.PageCount = this.PageCount+3
>this.MemberClass = "TypeCPage"
>this.PageCount = this.PageCount+1
>
>
>You may need to manipulate other properties like Page.Caption, etc. to be what you need them to be.
>
>
>>Hi Fred, thanks for your reply.
>>I am using VFP8 but have not used these new propertied before.
>>I'd appreciate it if you could give me an example of how these might be used .
>>
>>Regards,
>>
>>Gerard
>>
>>
>>>>Hi.
>>>>I have all my classes set up and now want the Caption on each page of a Pageframe to be emboldedned and am having difficulty doing this.
>>>>
>>>>I tried first to sub class a Page.. I can do this ok
>>>>But on the PageFrame, I cannot change the Class of the Page
>>>>Also, there are only two pages on my base Subclassed Pageframe. if I have a Pageframe with more than 2 pages, can I get these pages to automaticvally inherit from my own subclassed page class
>>>>
>>>>Thanks for any help.
>>>>
>>>>regards,
>>>>
>>>>Gerard
>>>
>>>With VFP8 you can do this using the MemberClass and MemberClassLibrary properties. Prior to VFP8, you can do it programmatically, but not visually.
Previous
Reply
Map
View

Click here to load this message in the networking platform