Solved

Remove item from generic list

Posted on 2013-10-31
2
451 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

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Visual Studios 1 76
location of a form 2 24
Linq asp.net mvc 13 17
VB.net -  GroupBox / Panel DataBinding and behavior 3 11
Problem Hi all,    While many today have fast Internet connection, there are many still who do not, or are connecting through devices with a slower connect, so light web pages and fast load times are still popular.    If your ASP.NET page …
Entity Framework is a powerful tool to help you interact with the DataBase but still doesn't help much when we have a Stored Procedure that returns more than one resultset. The solution takes some of out-of-the-box thinking; read on!
The Email Laundry PDF encryption service allows companies to send confidential encrypted  emails to anybody. The PDF document can also contain attachments that are embedded in the encrypted PDF. The password is randomly generated by The Email Laundr…

792 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