how we create a function/method in vb.net??
if i want to make a method of auto_generate_id,
then how will i start?
i have written this code please help me.....
void auto_generate_id()
Dim j As Integer = 0
Dim cmd As New SqlCommand("select staffid from staff order by staffid", c.con)
Dim dr As SqlDataReader()
dr=cmd.executereader()
while(dr.read())
txtstaff_id.text=dr("staffid").tostring()
end while
j=converttoint32(txtstaff_id.text.to string())
j=j+1
txtstaff_id.text=j.to string()
dr.close()
c.con.close()
end sub
please help me........