Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Visible Properties
Message
De
04/08/2001 15:11:35
Nancy Folsom
Pixel Dust Industries
Washington, États-Unis
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Programmation Orientée Object
Divers
Thread ID:
00539784
Message ID:
00539828
Vues:
8
>To all,
>
> If I have a container that has 30 buttons and all 30 buttons are VISIBLE = .T., but the container is VISIBLE = .F., do the buttons within the container get refreshed when the screen does.

Yes. One reason the REFRESH() can be a pretty scary place to put code. It runs _often_.

> We're trying to track a slow down within our system. The coverage profiler is helpful but doesn't truly help with refresh issues.

I think it's simpler in this case to just make a little test case. Here's what I used.
**************************************************
*-- Class Library:  c:\temp\test.vcx
**************************************************


**************************************************
*-- Class:        btntest (c:\temp\test.vcx)
*-- ParentClass:  commandbutton
*-- BaseClass:    commandbutton
*-- Time Stamp:   08/04/01 12:04:00 PM
*
DEFINE CLASS btntest AS commandbutton


	Height = 27
	Width = 84
	Caption = "Command1"
	Name = "btntest"


	PROCEDURE Refresh
		WAIT "In " + this.Name + ".refresh()" WINDOW TIMEOUT 1
	ENDPROC


ENDDEFINE
*
*-- EndDefine: btntest
**************************************************


**************************************************
*-- Class:        cnttest (c:\temp\test.vcx)
*-- ParentClass:  container
*-- BaseClass:    container
*-- Time Stamp:   08/04/01 12:05:03 PM
*
DEFINE CLASS cnttest AS container


	Width = 102
	Height = 138
	Visible = .F.
	Name = "cnttest"


	ADD OBJECT btntest1 AS btntest WITH ;
		Top = 12, ;
		Left = 10, ;
		Name = "Btntest1"


	ADD OBJECT btntest2 AS btntest WITH ;
		Top = 42, ;
		Left = 10, ;
		Name = "Btntest2"


	ADD OBJECT btntest3 AS btntest WITH ;
		Top = 72, ;
		Left = 11, ;
		Name = "Btntest3"


	ADD OBJECT btntest4 AS btntest WITH ;
		Top = 103, ;
		Left = 11, ;
		Name = "Btntest4"


ENDDEFINE
*
*-- EndDefine: cnttest
**************************************************


**************************************************
*-- Class:        test (c:\temp\test.vcx)
*-- ParentClass:  form
*-- BaseClass:    form
*-- Time Stamp:   08/04/01 12:05:14 PM
*
DEFINE CLASS test AS form


	DoCreate = .T.
	Caption = "Test form"
	Visible = .T.
	Name = "test"


	ADD OBJECT cnttest1 AS cnttest WITH ;
		Top = 43, ;
		Left = 59, ;
		Name = "Cnttest1", ;
		Btntest1.Name = "Btntest1", ;
		Btntest2.Name = "Btntest2", ;
		Btntest3.Name = "Btntest3", ;
		Btntest4.Name = "Btntest4"


	ADD OBJECT command1 AS commandbutton WITH ;
		Top = 71, ;
		Left = 205, ;
		Height = 27, ;
		Width = 84, ;
		Caption = "Command1", ;
		Name = "Command1"


	PROCEDURE command1.Click
		THISFORM.REFRESH()
	ENDPROC


ENDDEFINE
*
*-- EndDefine: test
**************************************************
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform