Now Place:2uzhan.com » dropdown


Software Development @ July 3, 2009   Views:0

i have a problem in dropdown :suppose i select id from dropdown then i want name of the employee is displayed matched with that id is displayed in textbox : i have use the following code

con = New SqlConnection(constr)
adpt = New SqlDataAdapter("select * from reg where f_name='" + DropDownList1.SelectedItem.Text.ToString + "' ", con)
ds = New DataSet
If ds.Tables(0).Rows.Count - 1 >= 0 Then
TextBox1.Text = ds.Tables(0).Rows(0).Item(11)
End If



This is your 38th post and you post source code without bb code tags. I think you haven't read - How to use bb code tags?.

Wrap up source code with bb code tags.

the logic u r using is incorrect.
use a looping statement.
traverse each record of the data set using this loop.
inside the loop check for the matching id.
when its found u display that information in the text box and then u break out of the loop

I'm attempting to simplify my fundraising page, and would like to show exactly how much each donation would help us out. I've listed the options below, but I would like ...

Write a java program that asks a person for his height (in meters) and weight (in kilograms) and
outputs one of the messages: underweight, normal, or obese, using the BMI ...

Before I get into the specific issues, I want to provide some other details:

  • Normally, I work on a live, paid server (even in dev); I realize that is ...
© 2018 2uzhan.com Contact