Information générale
Titre:
Replacing Column Controls in Grid at Runtime
All,
I am replacing column controls at runtime with custom classes in a grid. After the substitution, the controls no longer contain any information. What am I doing wrong? The code is as follows:
LOCAL ;
loColumn,;
lcCurrentControlName,;
lcAddingControlName
FOR EACH loColumn IN This.Columns
IF EMPTY(This.aControlType[loColumn.ColumnOrder])
LOOP
ENDIF
lcAddingControlName = This.aControlType[loColumn.ColumnOrder]
lcCurrentControlName = loColumn.CurrentControl
WAIT WINDOW "Now exchanging " + lcAddingControlName + " for " + lcCurrentControlName NOWAIT
loColumn.RemoveObject(lcCurrentControlName)
loColumn.AddObject(lcCurrentControlName,lcAddingControlName)
loColumn.CurrentControl = lcCurrentControlName
ENDFOR
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