I completely agree with @Sergey Alexandrovich Kryukov and my advice to you would be before posting a question just try to learn how to ask a question which can be understood by others.
Now what new in this solution?
I can assume your question in two way.
Q. How to get values from a list which are not present in another list in C#?
Ans: Basically, how to compare two lists in C#.
Note:
List in C# represents a strongly typed list of objects that can be accessed by index.
var firstNotSecond = list1.Except(list2).ToList();
Reference:
http://stackoverflow.com/a/12795900/1006297[
^]
Q. How to get values of items from a listbox which are not present in another listbox in C#?
Ans:
List<string> myList = new List<string>();
for(int i = 0; i < listbox1.Items.Count; i++)
{
for(int j = 0; j < listbox2.Items.Count; j++)
{
if (listbox2.Items[j].ToString() == listbox1.Items[i].ToString())
{
break;
}
else if((j+1)==listbox2.Items.Count)
{
myList.Add(listbox2.Items[j].ToString())
}
}
}</string></string>
After the loop is finished you can get the required list of values in
myList.
Hope, it helps :)
In case your requirement is something different than this, please try adding more information to your question.