I'm preparing an shopping cart website by using open source code of NopCommerce with Telerik RadControls for different look-and-feel of the shopping cart. But in AddtoCart functionality selectAttribute function is not working properly. I'm using RadPanelBar instead of placeholder to bind all attributes dynamically but selectAttributes function will not get values of dynamically created RadPanelItem inside RadPanelBar. So the selectedvalues of attributes are null please help me to find the solution of the problem.

I added few dropdowns and check-boxes under a RadPanel bar dynamically.

My RadPanelBar structure is like -

RadPanelBar1
<Items>
<RadPanelItem Text=”Size”>
<Items>
<RadPanelItem>ComboboxValue1</RadPanelItem>
<RadPanelItem>ComboboxValue2</RadPanelItem>
<RadPanelItem>ComboboxValue3</RadPanelItem>
</Items>
</RadPanelItem>
<RadPanelItem Text=”Color”>
<Items>
<RadPanelItem>ComboboxValue1</RadPanelItem>
<RadPanelItem>ComboboxValue2</RadPanelItem>
<RadPanelItem>ComboboxValue3</RadPanelItem>
</Items>
</RadPanelItem>
</Items>
RadPanelBar1
All items of the RadPanelbar is created dynamically I need the values of controls say Combobox here.

Below is the code to get the values of combo:
case AttributeControlTypeEnum.DropdownList:
   {
       var ddlAttributes = RadPanelBar1.FindControl(controlId) as DropDownList;  ------ it will show null value
  //  var ddlAttributes = phAttributes.FindControl(controlId) as DropDownList;  ---- This is a asp placeholder which is running properly in NopCommerce
     if (ddlAttributes != null)
        {
            int selectedAttributeId = 0;
           if (!String.IsNullOrEmpty(ddlAttributes.SelectedValue))
            {
                  selectedAttributeId = int.Parse(ddlAttributes.SelectedValue);
              }
           if (selectedAttributeId > 0)
           {
            selectedAttributes = ProductAttributeHelper.AddProductAttribute(selectedAttributes,attribute, selectedAttributeId.ToString());
          }
      }
}