Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Jumping form
Message
De
14/09/2004 14:14:10
 
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Titre:
Divers
Thread ID:
00941567
Message ID:
00942022
Vues:
23
> Hello Stefan,
> NODEFAULT in form.move() did not work(i just put NODEFAULT in method.what
> condition it needs. and what do you mean "BY DESIGN"?)
> return .f. from grid.when() works!, but user can't get to the grid. and we
> need that.I am still in limbo.

Grids and also Browse windows do jump back into the visible _screen when they are activated, and I *believe that was originally meant as a feature in old Fox versions.

As for the conditional .F. returned by When(), the sample.prg below was made for a slightly different scenario but may explain better than my broken English.


hth
-Stefan
* form_unintended_move.prg
&& run this and then activate the new form, e.g. use Ctrl+F1
&& repeatedly, to make it jump

#define B_WORKAROUND .f.


PUBLIC oForm as Form
oForm = CREATEOBJECT('TestForm')
oForm.Show()

oForm.Move(_screen.Width-20,0)
* form with grid does not want to move so far,
* so we move it manually
ACTIVATE WINDOW command
KEYBOARD 'oForm.Left = oForm.Left + 1'
KEYBOARD '{ENTER}'

RETURN

DEFINE CLASS TestForm as Form
	PROCEDURE Init
		CREATE CURSOR temp (f1 I, f2 I)
		INSERT INTO temp VALUES (1,1)
		This.AddObject('oGrid','TestGrid')
		This.oGrid.Visible = .T.
	ENDPROC
ENDDEFINE

DEFINE CLASS TestGrid as Grid
#if B_WORKAROUND
	PROCEDURE When
		RETURN Thisform.Left < _screen.Width - 50
	ENDPROC
#endif
ENDDEFINE
* eop
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform