Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Prevent User From Leaving Form
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Divers
Thread ID:
00383396
Message ID:
00383488
Vues:
47
Hi Nick,

>the form becomes visible and VFP comes up with an error "Cannot change modality of a visible form"

The following works for me in VFP5 and VFP6/SP3 on Windows 2000. I can use the buttons to switch between modal and modeless. Does it work for you?
Public oForm
oForm = CreateObject("SwitchForm")
oForm.Show()

Define Class SwitchForm as Form
	Add Object cmdModal as CommandButton With Caption="Modal"
	Add Object cmdModeless as CommandButton With ;
		Caption="Modeless", ;
		Top = 50
	Procedure cmdModal.Click
		Thisform.Hide()
		Thisform.Show(1)
		Thisform.Show(2)
	Procedure cmdModeless.Click
		Thisform.Hide()
Enddefine
Christof
--
Christof
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform