Hi ,
Good Morning

Happy Sivaratri to all of u guys.

Please help me. I'm struck in the program.

I have two dropdown listboxes. one is to add the values in the panel and the other is to show the values in the same panel.
When I changed the item in the values of the dropdown then the added list of the previous item has to be disabled.
I'm trying all different ways but it doesn't work. Please help its urgent.
Warm Regards,
Srinivas

Happy Sivaratri to you.

>I'm trying all different ways but it doesn't work.

bool changed = false;

        foreach (ListItem l in DropDownList1.Items)
        {
            if (!DropDownList2.Items.Contains(l))
            {
                changed =true;
            }
        }
        if (changed)
            //
        else
            //
Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.