Skip to content

Getting the control in a WebForm

RommeL

Asked Oct 9, 2008, 10:01 PM EDT1 answer
Share
LinkedInX
this is my code there are error in it can someone tell me how to correct this?

            foreach (System.Web.UI.Control ctrl in Table)
            {
                if (ctrl is DropDownList)
                {
                    DropDownList dd = new DropDownList(ctrl);
                    break;
                }
            }

1 Answer

Know the answer? Post it. Somebody with the same question will find it here.

  • +1

    please provide more code. have you tried renaming "dd" to "ctrl"? ... probably a stupid question

    +1