Hai to all
I am doing a project in vb.net in my database i have 5 different titles .
the following coding are used for database retrieving the database datas.
(<pre lang="vb">Try
conopen()
cmd = New SqlCommand("select PROJECT_TITLE from PRO_DETAILS ", con)
ada = New SqlDataAdapter(cmd)
ds = New DataSet()
ada.Fill(ds)
Dim i, a As Integer
a = ds.Tables(0).Rows.Count
For i = 0 To a - 1
rw = ds.Tables(0).Rows(i)
ComboDDtitle.Items.Add(rw("PROJECT_TITLE").ToString())
Next
Catch ex As Exception
MsgBox("Error")
End Try</pre>
)
but it running the count up to five times ,but i want only one time run it and displayed in the combobox for choosing a particular title.
Thanks in Advance,
Rajeshkumar