Information générale
Catégorie:
Codage, syntaxe et commandes
Versions des environnements
Add a call to oGrid.Refresh() method to refresh the grid display after changing the order; this works for me.
As for adding code in an "Event" for a control, there is not a problem. For example, if you add code directly in the .Click() event for a commandbutton and then call that code somewhere else, it DOES NOT trigger the Click event of the commandbutton; it only executes the code contained in the .Click() method. The Click event is not performed by VFP only the code contained in the method. The code in the Click() event is the action that will be taken when a user clicks on the button; the code is not the action. You have to use a mouse to trigger the event (user interaction) or use RAISEEVENT() command.
I know that many will have problems with this and this will trigger many responses, but I generally ignore them (same arguments with the M dot notation - some use it as gospel and some do not). In both cases (event/method and m-dot) it is important to understand how it works and take actions when there might be a problem.
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