Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
DataBinding with DataView
Message
De
28/07/2004 01:57:19
 
 
À
28/07/2004 01:26:57
Information générale
Forum:
ASP.NET
Catégorie:
Autre
Divers
Thread ID:
00928591
Message ID:
00928599
Vues:
25
Hi, Mike,

Without seeing the actual code, I can't say for certain, but here's a code sample for something similar. See if there's anything here that might help...
dataGrid1.DataSource = MyData.Tables[0].DefaultView;
DataGridTableStyle style = new DataGridTableStyle();
style.MappingName =  "MyTableName";

DataGridTextBoxColumn fld1 = new DataGridTextBoxColumn(); 
fld1.HeaderText = "First Name";
fld1.MappingName = "firstname";

DataGridTextBoxColumn fld2 = new DataGridTextBoxColumn(); 
fld2.HeaderText = "Last Name";
fld2.MappingName = "lastname";

style.GridColumnStyles.AddRange(new DataGridColumnStyle[] {fld1, fld2 });
dataGrid1.TableStyles.Clear();
dataGrid1.TableStyles.Add(style);
Does that help?
Kevin
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform