Subdiviser ou Fusionner l'entete d'un DataGrid en vb.net
cs_othinakiway
Messages postés30Date d'inscriptionlundi 7 avril 2008StatutMembreDernière intervention10 juin 2009
-
30 avril 2009 à 12:42
cs_othinakiway
Messages postés30Date d'inscriptionlundi 7 avril 2008StatutMembreDernière intervention10 juin 2009
-
30 avril 2009 à 12:46
salut,
deouis pas mal de temps je cherchais à comment faire pour fusionner ou fractionner les entête d'un datagrid, donc g trouvé cette source en C#:
1.private void DataGrid1_PreRender(object sender, System.EventArgs e) {
2.DataGridItem dgItem = new DataGridItem (0, 0, ListItemType.Header);
3.TableCell tbCell = new TableCell();
4.tbCell.ColumnSpan =12;// Set it to the colspan that you want
5.tbCell.Text = "Category Information";
6.tbCell.Attributes.Add("style", "text-align:center" );
7.dgItem.Cells.Add(tbCell);
8.DataGrid1.Controls[0].Controls.AddAt(0, dgItem);
9.}
y'a t'il qqun qui peut me donner le code en vb.net ou me proposer une solution.
merci d'avance
A voir également:
Subdiviser ou Fusionner l'entete d'un DataGrid en vb.net
cs_othinakiway
Messages postés30Date d'inscriptionlundi 7 avril 2008StatutMembreDernière intervention10 juin 20092 30 avril 2009 à 12:46
dsl, c un peur mal organisé tt sa voila le code en C# :
1.private void DataGrid1_PreRender(object sender, System.EventArgs e) {
2.DataGridItem dgItem = new DataGridItem (0, 0, ListItemType.Header);
3.TableCell tbCell new TableCell(); 4.tbCell.ColumnSpan12;// Set it to the colspan that you want
5.tbCell.Text = "Category Information"; 6.tbCell.Attributes.Add("style", "text-align:center" );
7.dgItem.Cells.Add(tbCell);
8.DataGrid1.Controls[0].Controls.AddAt(0, dgItem);
9.}
y'a t'il qqun qui peut me donner le code en vb.net ou me proposer une solution. merci d'avance