Information générale
Titre:
Color wrong at startup
I have a winform that has a datagridview on it. When I start the form I bind a datasource to the grid and then set a specific cell to a set color based on the value in that cell. The color change does not take effect at startup. However if I call that cell color function after the form is displayed (clicking on a button) then the cells all color properly.
I'm assuming that this has to do with the loading of the datagridview but I can't track it down.
Anyone got any suggestions on this?
This is the code I call at start up
public yardmngt()
{
InitializeComponent();
FillHeaderGrid(); // fills datagrid with data and sets color
dgheader.ContextMenuStrip = CMOrdHeader;
dglineitems.ContextMenuStrip = CMOrdLineItem;
}
Thanks
Alan Wyne
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