Couldn't find a way to resizing rows..does anyone knows how is it done?
currently doing...
.net2008 Code:
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click Cursor.Current = Cursors.WaitCursor DataGridEntidades.DataSource = giveDataSet("select CodEntidade AS Cod, NomeEntidade AS Nome, MoradaEntidade AS Morada, Telefone1 AS Contacto from entidades where CodEntidade LIKE '%" & Trim(txtEntidade.Text) & "%' OR NomeEntidade LIKE '%" & Trim(txtEntidade.Text) & "%' OR MoradaEntidade LIKE '%" & Trim(txtEntidade.Text) & "%' OR CPEntidade LIKE '%" & Trim(txtEntidade.Text) & "%' OR Telefone1 LIKE '%" & Trim(txtEntidade.Text) & "%' ORDER BY NomeEntidade") 'DataGridEntidades.Refresh() Cursor.Current = Cursors.Default End Sub
Frustrated attempt resizing columns...
.net 2008 Code:
Try Dim ts As New DataGridTableStyle ts.MappingName = "Entidades" DataGridEntidades.TableStyles.Clear() DataGridEntidades.TableStyles.Add(ts) DataGridEntidades.TableStyles("Entidades").GridColumnStyles(1).Width = 10 Catch ex As Exception ' End Try
Does anyone has any clue why is this happening?
Thanks




and rating it.
Reply With Quote