Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How to use a container across multiple pages in pagefram
Message
From
13/05/2005 06:48:48
 
 
To
12/05/2005 22:41:55
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Miscellaneous
Thread ID:
01013681
Message ID:
01013763
Views:
16
I believe you can add this container to the FORM and set it's zorder to 0 (Bring to Front) over the pageframe. It then would exist only once but appear on each page.
PUBLIC oform1

oform1=NEWOBJECT("form1")
oform1.Show
RETURN


	**************************************************
*-- Form:         form1 (c:\dev\vdev\val\val5\demo.scx)
*-- ParentClass:  form
*-- BaseClass:    form
*-- Time Stamp:   05/13/05 06:48:14 AM
*
DEFINE CLASS form1 AS form


	Caption = "Form1"
	Name = "Form1"

	ADD OBJECT pageframe1 AS pageframe WITH ;
		ErasePage = .T., ;
		PageCount = 2, ;
		Top = 13, ;
		Left = 14, ;
		Width = 359, ;
		Height = 239, ;
		Name = "Pageframe1", ;
		Page1.Caption = "Page1", ;
		Page1.Name = "Page1", ;
		Page2.Caption = "Page2", ;
		Page2.Name = "Page2"

	ADD OBJECT container1 AS container WITH ;
		Top = 208, ;
		Left = 17, ;
		Width = 349, ;
		Height = 31, ;
		BackStyle = 0, ;
		BorderWidth = 0, ;
		Name = "Container1"


	ADD OBJECT form1.container1.command1 AS commandbutton WITH ;
		Top = 8, ;
		Left = 30, ;
		Height = 17, ;
		Width = 59, ;
		Caption = "Command1", ;
		Name = "Command1"


	ADD OBJECT form1.container1.command2 AS commandbutton WITH ;
		Top = 8, ;
		Left = 122, ;
		Height = 17, ;
		Width = 59, ;
		Caption = "Command1", ;
		Name = "Command2"


	PROCEDURE Init
		this.pageframe1.ZOrder(1)
		this.container1.ZOrder(0)
	ENDPROC


ENDDEFINE
*
*-- EndDefine: form1
**************************************************
Glenn

>I have a container with navigation controls and status indicators that I would like to reuse on multiple pages in a pageframe. For visual consistency, I would like this container to sit within each page vs. exist outside the pageframe.
>
>Right now I've manually add this container to each page of my pageframe that needs this container's functionality. This doesn't seem too efficient. I'm wondering if there's a better way to implement this? In other words some way to have a single copy of this container "move" between active pages as necessary.
>
>Hope this makes sense,
>
>Malcolm
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform