Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
425
Webdropdown SelectedIndexChanged JavaScript not working
posted

Hi All,

I'm having multi select webdropdowns and on selectedindexchanged event i need to add the VALUE fields to a string, But i'm not able to get the VALUE fields of webdropdown rather i'm getting the INDEX i,e if 1st and 5th items are selected in the dropdown i'm getting the values 1, 5..

I tried using get_currentValue() but it is throwing an error object of type  not supported.. Below is the script for that, Kindly look into this..

<code>

for (i = 0; i < newItems.length; i++)
    {
        if (sender._id == "cph1_ddlPC")
        {
            if (newItems[i].get_index() < 10)
            {
                newItemsString += "0" + newItems[i].get_currentValue() + ", ";
            }
            else
            {
                newItemsString += newItems[i].get_currentValue() + ", ";
            }
        }
        else
        {
            newItemsString += newItems[i].get_currentValue() + ", ";
        }
    }

</code>

Parents Reply Children
No Data