Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Switchboard Form Problems
Message
De
07/04/2004 17:02:45
 
 
À
Tous
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Titre:
Switchboard Form Problems
Divers
Thread ID:
00893093
Message ID:
00893093
Vues:
85
I have a small switchboard form that has three buttons on it. Each button opens a form. However, when I click on any of the buttons, the 2nd form is instantiated and jumps to the forefront but after instantiating itself it immediately runs the form's unload and releases the form. Focus is returned to the switchboard form and it is then the only form still available. Why would this happen?

Here is code in the command button:
PRIVATE llfound
llfound = .F.
FOR EACH loForm IN _VFP.FORMS
	IF VARTYPE(loForm) = "O" AND pemstatus(loForm, "BaseClass", 5) AND loForm.BASECLASS = "Form" AND loForm.NAME != "Startup"
		IF UPPER(loForm.NAME) = 'CPDF'
			llfound = .T.
			IF loForm.WindowState=1
				loForm.LockScreen = .T.
				loForm.WindowState = 0
				loForm.LockScreen = .F.
			ENDIF
			loForm.refresh()	
			loForm.Show(loForm.WindowType)
		ENDIF
	ENDIF
ENDFOR
IF !llfound
        *--This runs and then form releases itself for some reason
	DO FORM cpdf NAME ocpdf LINKED 
ENDIF
.·*´¨)
.·`TCH
(..·*

010000110101001101101000011000010111001001110000010011110111001001000010011101010111001101110100
"When the debate is lost, slander becomes the tool of the loser." - Socrates
Vita contingit, Vive cum eo. (Life Happens, Live With it.)
"Life is not measured by the number of breaths we take, but by the moments that take our breath away." -- author unknown
"De omnibus dubitandum"
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform