Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Move grid column without firing header's click()
Message
De
22/06/2005 10:02:39
 
 
À
22/06/2005 09:40:43
Mike Sue-Ping
Cambridge, Ontario, Canada
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Versions des environnements
Visual FoxPro:
VFP 8 SP1
Divers
Thread ID:
01025428
Message ID:
01025445
Vues:
24
>Hi,
>
>I have a VFP grid on a form. In the grid's columns' headers' click() event, there is code to sort that column (ascending/descending). One side effect is that when I move a column by dragging and dropping it to the new position, the sort is also fired.
>
>Anyone have suggestions as to how to avoid the sorting after moving the column?
>
>TIA
>
>Mike

Mike,

Another possibility
&& add these properties to the header
	_nXCoord = 0
	_nYCoord = 0

&& in the mousedown()
this._nXCoord	= m.nXCoord
this._nYCoord	= m.nYCoord


&& in the mouseup()
#define _NOT_MOVED	(	;
				( m.nXCoord == m.this._nXCoord ) ;
			and	( m.nYCoord == m.this._nYCoord ) ;
			)

do case
case  _NOT_MOVED
    && do your thing

endcase
Gregory
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform