Solved

Remove item from generic list

Posted on 2013-10-31
2
444 Views
Last Modified: 2013-10-31
Hi

I am trying to remove an item from a generic list, I have been using the code below but it does not remove the item.

 _oM04_UserManager = New M04_UserManager
                Dim oM04_UserList As List(Of M04_User)
                oM04_UserList = _oM04_UserManager.GetAllUsersForAllCompanies(_userId)
                oM04_UserList.RemoveAll(Function(p As M04_User) p.UserID = "5833aeb8-13e7-44e5-b60d-600395f5cdab")

Would be grateful for any advice

Thanks
0
Comment
Question by:Soluga
2 Comments
 
LVL 44

Accepted Solution

by:
AndyAinscow earned 500 total points
ID: 39613982
Does the list actually have an item with that exact ID ?
0
 
LVL 1

Author Closing Comment

by:Soluga
ID: 39614108
Doh!

Thanks
0

Featured Post

What Should I Do With This Threat Intelligence?

Are you wondering if you actually need threat intelligence? The answer is yes. We explain the basics for creating useful threat intelligence.

Join & Write a Comment

Calculating holidays and working days is a function that is often needed yet it is not one found within the Framework. This article presents one approach to building a working-day calculator for use in .NET.
It was really hard time for me to get the understanding of Delegates in C#. I went through many websites and articles but I found them very clumsy. After going through those sites, I noted down the points in a easy way so here I am sharing that unde…
Illustrator's Shape Builder tool will let you combine shapes visually and interactively. This video shows the Mac version, but the tool works the same way in Windows. To follow along with this video, you can draw your own shapes or download the file…
This video explains how to create simple products associated to Magento configurable product and offers fast way of their generation with Store Manager for Magento tool.

706 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now