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
1175
DropDown EnableDropDown as Child property seems buggy
posted

Hello there,

I have a webdatagrid, in which a webdropdown is activated.

I load the webdropdown like this:

        private void FillIndRoleAttribDropDown(DropDown control, TmpIndRoleAttribute tmpAttr)
        {
            List<INDROLE_ATTRIBUTE_TYPE> types = GetRoleAttributeTypes();
            control.DataSource = types;
            control.ValueField = "IR_ATTR_TYPE_CDE";
            control.TextField = "DESCR";
 
            control.DataBind();

            control.Enabled = (tmpAttr.IR_ATTR_ID < 0);

            if (!string.IsNullOrEmpty(tmpAttr.IR_ATTR_TYPE_CDE))
                control.SelectedItemIndex =
                    types.Select(r => r.IR_ATTR_TYPE_CDE).ToList().IndexOf(tmpAttr.IR_ATTR_TYPE_CDE);
            else
                control.Items.Insert(0, new DropDownItem(PrfUIConstants.AdditionalItmes.NotSelected, string.Empty));
        }

I shoot this code at the initialize-row event of the grid.

The problem is, I get a strange flickering, when I open this list of this dropdown. I found in the internet the solution, to set the EnableDropDownAsChild Property to false and set the z-index as high as possible.

This might fix the flickering problem, but now I cant open the dropdown, when a value is selected. I tried to set the EnableAutoCompleteFirstMatch Property to false, but this didnt work.

Is there a solution for this?

Matthias