URGENT help needed. Trying to get panels to work...

  • Thread starter Thread starter TN Bella
  • Start date Start date
T

TN Bella

I downsized my code below...my text boxes work out okay with this
format, it is just the dropdownboxes that give me an error. I need this
to work so I can press on with other pressing things...thanks for the
help! Right now I am so far behind.

Compiler Error Message: BC30456: 'text' is not a member of
'System.Web.UI.WebControls.DropDownList'.
Line 29: litResponse.text+="<b>Invoice Location</b>:" &
txtInvLoc.text & "<br>"

Sub doInsert(Source as Object, E as EventArgs)
pnl2.visible="true"
litResponse.text+="<b><i>The information provided is now being
processed</b>.<p>"
litResponse.text+="<b>Invoice Location</b>:" & txtInvLoc.text &
"<br>"
End Sub

<td>
Invoice
Location&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
<asp:dropdownlist id="txtInvLoc"
runat="server" Width="200px">
<asp:ListItem
Value="001">001</asp:ListItem>
<asp:ListItem
Value="002">002</asp:ListItem>
<asp:ListItem
Value="003">003</asp:ListItem>
</asp:dropdownlist>
<br />
</td>


*** Sent via Devdex http://www.devdex.com ***
Don't just participate in USENET...get rewarded for it!
 
You can't get the selected drop-down text or value this way. Try
txtInvLoc.SelectedValue, or txtInvLoc.SelectedItem.Text.

- gsk.
 
Thanks for the reply. Since I am using 1.0 .net framework I had to set
it up like this:

litResponse.text+="<b>Invoice Location</b>:" &
txtInvLoc.Items(txtInvLoc.SelectedIndex).Value & "<br>"

Have a great day!



*** Sent via Devdex http://www.devdex.com ***
Don't just participate in USENET...get rewarded for it!
 
Back
Top