Quantcast
Channel: Windows Forms Data Controls and Databinding forum
Viewing all articles
Browse latest Browse all 2535

Printing last cell value of data table on label control

$
0
0

Dear Friends ...

Please see the table screen shot from my database. I need to print the last value in TID column from database table (in this example TID no is 12)  in label1 by clicking button2 on vb.net salesmysql form.

so far my code here is

Private Sub Button2_Click(sender As System.Object, e As System.EventArgs) Handles Button2.Click
        conn.Open()
        Dim ds As New DataSet
        Dim da As New MySqlDataAdapter("select TID from mydatabase.tbltran;", conn)
        da.Fill(ds, "mydatabase.tbltran")

    End Sub


Viewing all articles
Browse latest Browse all 2535

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>