|
Hi,
How do I get the value of the text selected in a dropdown list? I can get the value of it like this:
objOrder.Type = Int32.Parse(cboOrderTypes.SelectedValue);
But how do I get the text that is displayed to the user in the dropdown into a variable?
I hope someone can help??
Regards,
ma se
|
|
|
|
|
to get the selected items text in a variable you can get like this:
cboOrderTypes.SelectedItem.Text
or if you want to get the value of the selected item then like this you can get:
cboOrderTypes.SelectedItem.Value.ToString()
Best Regards,
Apurva Kaushal
|
|
|
|
|
Thanks this works just fine.
|
|
|
|
|
always welcome
Best Regards,
Apurva Kaushal
|
|
|
|
|
|
use DropDownList1.SelectedItem.Text property for text.
Nav.
-- modified at 5:22 Monday 24th July, 2006
|
|
|
|
|
There is no selectedtext property.
|
|
|
|
|
you can get like
SelectedItem.Text
Best Regards,
Apurva Kaushal
|
|
|
|
|
Thanks but I managed with it.
|
|
|
|
|
sorry its SelectedItem.Text ....
Nav.
|
|
|
|
|
Yes I know. I also thought it would be something like SelectedText because there is a SelectedValue.
But thanks for getting back anyways.
Cheers.
|
|
|
|
|
hi,
how to create a FolderBrowser in ASP.net.
iam referring to the "browse button" and the text box to display the path of the selected """ Folder""" not """"File""""?
kamalnath
|
|
|
|
|
don't create a new thread for same question. If you want to answer(or want to re ask a question for that answr) then just click reply and paste your comments.
Best Regards,
Apurva Kaushal
|
|
|
|
|
|
hi
that is for file uplode.Iam asking "Folder Browser" in ASp.net
kamalnath
|
|
|
|
|
|
HI
Can any one plz let me know how to find the tree node in tree control of .net 2.0 , i know i can find from the treeview.findnode method the parameter to pass it in is value path ,what is this value path can any one let me know asap,if any one can provide the example code it would be great ,thankx in advance,
regards
tippu
|
|
|
|
|
TreeView1.SelectedNode
Human knowlege belongs to the world
|
|
|
|
|
|
I have a procedure that outputs XML (with: FOR XML AUTO, ELEMENTS)
I want to read this data into somthing that can be used as a source for an ASP.NET XML tool.
I have tried using a string but there is too much data in some of the responces.
A code snippet or rough example of the proposed solution would be much apreciated.
Thanks.
|
|
|
|
|
I didn't think that a string had a maximum size... ? and if it's returning from the DB, can you not just load it directly into an XmlDocument object?
|
|
|
|
|
How Can I Add Dynamic WebControl (like TextBox) in may page
C# in Asp.Net 1.1
With Thanks
MHF
|
|
|
|
|
You can take a placeholder and add the webcontrols to that placeholder.
Best Regards,
Apurva Kaushal
|
|
|
|
|
Please Give me a sample
MHF
|
|
|
|
|
This article will be quite helpful to you.
http://msdn2.microsoft.com/en-us/library/kyt0fzt1.aspx
Best Regards,
Apurva Kaushal
|
|
|
|