How to take selected data from VB.net drop down list -


I am currently practicing Vibinet in Visual Studio 2013 and I was asked to create a data-down list table I'm down and working. What I am stuck is how to drag the selected option from the drop down list and use it to display the label in the web control to show on the screen when a button is pressed for selection, can anyone help?

My code file Default.aspx.vb

  dim dsData1 new datasets dsData1 = tableData as () DDList.DataSource = dsData1 DDList.DataValueField = "code" DDList.DataTextField = "Description" DDList.DataBind () DDList.Items.Insert (0, New ListItem (String.Empty, String.Empty)) DDList.SelectedIndex = 0  

my my Code file in function.vb

  public shared function tableData () datasets dim oraConnect New OracleConnection oraConnect.ConnectionString = ConfigurationManager.ConnectionStrings as ( "smart_dev") ConnectionString OracleCommand new as dim oraCommand oraCommand.Connection = oraConnect oraCommand .CommandType = Data.CommandType.Text string as dim lsSQL = "" lsSQL = "SELECT c ODE, details WHERE domain ref_code = 'special' 'new OracleDataAdapter as' oraCommand.CommandText = lsSQL (oraCommand) As dirty DS new dataset fill Fill (DS) back DS expiration function  

I need help for the code that I can edit one of these codes and with the code if I open the page in a browser, choose an option from the dropdown and is displayed on the screen.

Thank you

If I am confused with anybody then I apologize :)

I think that you seek

the
  DropDownList.SelectedItem.Text  

it is laying a trap .SelectedItem.Text only A. After archived will view state has been loaded, if you can do the following if you need to travel around:

dim selected text string = page. Request (DD List. UNICID)

Comments

Popular posts from this blog

winforms - C# Form - Property Change -

c# - NewtonSoft JArray - how to select multiple elements with LINQ -

javascript - amcharts makechart not working -