Okay, I've a List<String> object and RadCombobox.Items collection. I want to check all items whose values fall in that List.
Above all, this does not actually check those items, even if the condition in the "if statement" seems to be satisfied and it does execute the if block w/o any errors.
I'd love to get this doing by LINQ in a bit more efficient manner than that of below (100s of items folks, that's why I'm thinking of this as a reasonable thing to do)
I tried the Intersect but evidently, I can not compare RadComboBoxItem with a string even if I do so
Thanks you much,
-Aarsh
Above all, this does not actually check those items, even if the condition in the "if statement" seems to be satisfied and it does execute the if block w/o any errors.
I'd love to get this doing by LINQ in a bit more efficient manner than that of below (100s of items folks, that's why I'm thinking of this as a reasonable thing to do)
I tried the Intersect but evidently, I can not compare RadComboBoxItem with a string even if I do so
IEnumerable<
string
> AdditionalCategoryTypes = LoadAdditionalCategoryTypes(thisObj.ProductID);
foreach
(
string
val
in
AdditionalCategoryTypes)
{
if
(ddAdditionalCategoryTypes.Items.FindItemByValue(val) !=
null
)
ddAdditionalCategoryTypes.Items.FindItemByValue(val).Checked =
true
;
}
Thanks you much,
-Aarsh