-
Compare and removing elements
H1, Using VB Net (2005, Access (2003) in Windows Forms, I would like to know
What would be the best way to remove same elements found in a line of text, let me
Explain further my example: for this purpose I will name (line of text-1) and (line of text-2) for my 2 entity, (line of text-1) is being pull from a dataset.Tables(“tblSomeTable”).Rows(x).Item(13) that field may contains no more than 6 elements separated by coma, those elements are and will always be the same. Now for (line of text-2) I am thinking of something like this :
Dim List As String = {“Hardware”, “Labour”, “Part”, “Service”, “Software”, “Warranty”} Now that we have both entities, I would like to compare them and then remove elements in (line of text-2) that are found the same in (line of text-1) so I be able to add the remaining elements to a listBox. Hope to have been clear enough and hope that someone can help me. Thank you in advance.
-
Is your primary concern not to add duplicates to the listbox?
I don't answer coding questions via PM or Email. Please post a thread in the appropriate forum section.
Please use [Code]your code goes in here[/Code] tags when posting code.
Before posting your question, did you look here?
Got a question on Linux? Visit our Linux sister site.
Modifications Required For VB6 Apps To Work On Vista
-
Follow up
Hi, Mister Hack my concern is first is to compare both strings and see if string(Line of text-2) has some items found the first string(Line of text-1) if so then remove
those items from the string(Line of text-2) and then
populate a listBox with the remaining items of the string(Line of text-2). Thank you in advance
-
Hi , Is Mister Hack out on vacation, he ask a question, I answer now seem my tread is dead.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
Forum Rules
|
Top DevX Stories
Easy Web Services with SQL Server 2005 HTTP Endpoints
JavaOne 2005: Java Platform Roadmap Focuses on Ease of Development, Sun Focuses on the "Free" in F.O.S.S.
Wed Yourself to UML with the Power of Associations
Microsoft to Add AJAX Capabilities to ASP.NET
IBM's Cloudscape Versus MySQL
|
Bookmarks