Chtěl bych se zeptat,jak nastavím formátování buněk komponenty gridview? Pozor, načítám z databáze a potom rovnou do GridView.
Dim con As SqlConnection
Dim ada As SqlDataAdapter
Dim dst As DataTable
con = New SqlConnection("Data Source=databaze;Initial Catalog=CIGMA;User ID=user; Password=password;")
ada = New SqlDataAdapter("select partno,processcd,sum1st+sum2nd+sum3rd+sum4th+sum5th+sum6th+sum7th+sum8th+sum9th+sum10th+sum11th+sum12th+sum13th+sum14th+sum15th+sum16th+sum17th+sum18th+sum19th+sum20th+sum21th+sum22th+sum23th+sum24th+sum25th+sum26th+sum27th+sum28th+sum29th+sum30th+sum31th,sum1st,sum2nd,sum3rd,sum4th,sum5th,sum6th,sum7th,sum8th,sum9th,sum10th,sum11th,sum12th,sum13th,sum14th,sum15th,sum16th,sum17th,sum18th,sum19th,sum20th,sum21th,sum22th,sum23th,sum24th,sum25th,sum26th,sum27th,sum28th,sum29th,sum30th,sum31th from HsPrin where processcd = '" & DropDownList1.SelectedItem.Value & "' and resultsym = '" & TextBox1.Text & "' and [partno] like '" + TextBox2.Text + "%'", con)
dst = New DataTable
con.Open()
ada.Fill(dst)
con.Close()
|