Information générale
Catégorie:
The Mere Mortals .NET Framework
Titre:
Databinding combobox to non-existent column
Hi,
I get a NullReferenceException (NRE) if I bind a mmComboBox's display column to a non-existent column.
Line of code : mmBindigStrategy.cs line 894 - 895.
// Get the original column name and save it
DataColumn col = ds.Tables[tableName].Columns[displayColumnName];
string origColName = col.ColumnName;
In my business object's SQL I have a concatinated column which I want to show in the combobox. I type in by hand the column name in the combobox's BindingSourceDisplayMember but as usual I misspell the column name :)
Cheers,
Andrew
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