Information générale
Catégorie:
Gestionnaire d'écran & Écrans
Hi Elmer.
I take it that I would have to add a property .RowColChange to the grid to use your example code in the beforerowcolchange event. Where, when and what value would I assign to this new property to make this validation occur before the row change?
If you are using VFP 7.0, you do not need to add the RowColChange property. It is native. This is from the VFP 7 help file:
Contains a value that identifies the type of cell movement made in a grid. Readonly at design and run-time.
Grid.RowColChange Remarks
The value of RowColChange is 0 at opening and after refresh of a grid. You can query this property in AfterRowColChange and BeforeRowColChange events to determine the type of change that triggered the event, according to the following table.
Value Description
0 (default) No change.
1 Row change
2 Column change
3 Row and column change
My comment/rant was in no way intended to slam your workaround on this.
And I didn't take it as one < s >.
Call me a dreamer, but I would like to think that this basic functionality might someday be added to the grid control in some future release of VFP, so that a workaround would not be necessary < s >.
Actually, I think that the addition of the RowColChange property in 7, just about does it. The code I posted using the RowColChange property is all that is required to do the validation (except, of course, for the actual validation routine) < s >.
The original code was a workaround that I had come up with in version 6, back before this property was available.
Précédent
Suivant
Répondre
Voir le fil de ce thread
Voir le fil de ce thread à partir de ce message seulement
Voir tous les messages de ce thread
Voir tous les messages de ce thread à partir de ce message seulement