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

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!
 
G

GSK

You can't get the selected drop-down text or value this way. Try
txtInvLoc.SelectedValue, or txtInvLoc.SelectedItem.Text.

- gsk.
 
T

TN Bella

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!
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,580
Members
45,053
Latest member
BrodieSola

Latest Threads

Top