Vardhan - Friday, September 14, 2012 4:44 AM:
Hi all,
I have created an Itemtype and its form. The form has a dropdown field, values of dropdown are 'first','second','third' and 'final'.
By using VB.net I' m giving a condition based on dropdown selection like,
If choice= "first" Then 'choice is the property name of the field
'Do something
End If.
It is not giving the result. I'm not getting the string value of dropdown by using getProperty() and also by getPropertyAttribute(). In the 'list' If I give values to the choices as first=1,second=2..., then I can use like this
If(choice=1) Then
'Do something
Eng If
Here it working properly but I should use string in the If condition not integer values. How to get the String value from dropdown selection.
Please help me.
Thank You all,
Vardhan
Harsha - Friday, September 14, 2012 6:28 AM:
Hi Vardhan,
Try this
var fieldObj = parent.item.selectSingleNode("dropdown0");
if (fieldObj) {
var text = fieldObj.text;
}
Thank You,
Harsha
justinlee - Friday, September 14, 2012 11:40 PM:
Hi Vardh!
Dropdown control can't get value by method getPrperty(), it's control of JavaScript you must use method of JS,
AbhishekSrivastava - Saturday, March 26, 2016 6:18 AM:
Hi friends,
Can you please share your full sample code . I also involve in similar kind of work , So it will help me alot
Thanks in Advance
Abhishek Srivastava