Public conn As New SqlClient.SqlConnection
Dim SQLtile As String
conn = New SqlClient.SqlConnection("data source=SQL服务器IP;initial catalog=数据库名;user id=SQL用户;password=SQL密码;")
conn.Open()
SQLtile = "select * from s_update"
Dim RS_up As New DataSet
Dim DAup As New SqlClient.SqlDataAdapter
DAup.SelectCommand = New SqlClient.SqlCommand(SQLtile, conn)
DAup.Fill(RS_up)
TextBox1.Text=RS_up.Tables(0).Rows(第几行)("字段名")
[[it] 本帖最后由 qlong0728 于 2008-10-20 15:23 编辑 [/it]]