Information générale
Catégorie:
Codage, syntaxe et commandes
Titre:
Preventing Grid Navigation
Hi
I'd like to prevent the user navigating away from a record in a parent grid while the form is in editmode. This grid class is for use in a class library. This can be achieved in single-user systems by storing the recordnumber before going into editmode and checking RECNO() in AfterRowColChange(), then navigating back there. However the problems of user updates, delete conflicts etc. on multi-user systems are formidable.
I don't want to fiddle with the When() method of every textbox and column in my applications,and unless I use a builder 100% of the time it is tiresome to edit every object within every grid. In other words, I expect to use the base VFP header and textbox classes in grids at least some of the time. If I used custom classes for these 100% of the time, perhaps I could return .F. in When() if we're on the wrong record and everything might be OK. But that is quite a committment.
Any other ideas?? How can I write code into the When()s of certain contained objects at runtime, should I expect a new answer with the control of events in VFP 6.0...
TIA
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