Advertisement

05.10.2007 at 11:27AM PDT, ID: 22564863
[x]
Attachment Details
[x]
The Solution Rating System

With so many solutions, how can you tell which solutions are most likely to help you and which ones are not? To provide you with a tool to use, we rate our solutions based on various elements that most accurately determine if a solution is a quality solution. To explain what factors affect the solution rating, here are the elements we take into consideration when formulating our solution rating.

  • The Grade of the Solution
  • The Zone Rank of the Expert Providing the Solution
  • The Number of Author and Expert Comments
  • The Number of Experts Contributing
  • The Feedback of the Community

Your Input Matters
Because of the way the system is set up, the most important variable in this equation is you. As a member of Experts Exchange, you are able to cast your vote on the quality of the solutions in regard to how complete, accurate, helpful and easy to understand each solution is. When you provide your feedback, each rating is adjusted accordingly. So, if you see a solution that has a poor rating that you think is a good solution, let us know by rating it. As you do, the rating will be adjusted and will become more accurate for other members of our site.

If you have any suggestions that you would like to make for our rating system, please ask a question in the Suggestions Zone of Community Support.

Thank you!

7.4

Remove a value from a string array

Asked by Atropa in Microsoft Visual Basic.Net, Miscellaneous Programming, Visual Studio

Tags: , ,

I have a string that contains an array.  I want to remove one lousy value from the array but I can't seem to get it done. This is in VB.NET 2005 (.NET FW 2.0).  I populate the array in question by reading an external text file with array string in it, for example:
       aOU = {"ou=blah", "ou=fishcake", "ou=toothbrush"}
My code looks something like this:
       Dim OUArray As String
       Dim lOUArray() As String = oOU.Split(", ")
       OUArray = lOUArray
So now I have this OUArray and I put each item into a list box.  I have a few routines such as renaming a value in the array and so on.

What I want to do is allow the user to select an item in the list box (lbOU) and click a Remove OU button.  This ~should~ remove the ou from the array and when I re-populate the listbox from the updated array the OU should be gone.  I just CAN'T SEEM TO FIGURE OUT HOW TO REMOVE THE BLOODY ITEM FROM THE ARRAY!!!
I thought that I could do something like this, but it isn't working (Much to my chagrin):
       Dim iX As Integer = lbOU.SelectedIndex
       OUArray(iX).Remove()
-OR-
       OUArray.Remove(iX)
or something along those lines but that isn't working.  What am I missing here


Start Free Trial
[+][-]05.10.2007 at 11:40AM PDT, ID: 19067510

View this solution now by starting your 30-day free trial. Setting up your free trial is quick, easy, and secure. We will return you to this solution, unlocked, when you're done.

 

About this solution

Zones: Microsoft Visual Basic.Net, Miscellaneous Programming, Visual Studio
Tags: array, remove, string
Sign Up Now!
Solution Provided By: traxion
Participating Experts: 2
Solution Grade: A
 
 
[+][-]05.10.2007 at 11:46AM PDT, ID: 19067549

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]05.10.2007 at 12:02PM PDT, ID: 19067664

Assisted solutions are selected by the member who asked the question as a comment that contributed to their question's solution.

Start your 30-day free trial to view this Assisted Solution or ask the Experts your question.

 
[+][-]05.10.2007 at 12:06PM PDT, ID: 19067685

Assisted solutions are selected by the member who asked the question as a comment that contributed to their question's solution.

Start your 30-day free trial to view this Assisted Solution or ask the Experts your question.

 
[+][-]05.10.2007 at 12:08PM PDT, ID: 19067697

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]05.10.2007 at 12:09PM PDT, ID: 19067709

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]05.10.2007 at 12:17PM PDT, ID: 19067741

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]05.10.2007 at 12:19PM PDT, ID: 19067756

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]05.10.2007 at 12:59PM PDT, ID: 19068040

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]05.10.2007 at 01:00PM PDT, ID: 19068044

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]05.10.2007 at 01:04PM PDT, ID: 19068070

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]05.10.2007 at 02:27PM PDT, ID: 19068598

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]05.10.2007 at 02:28PM PDT, ID: 19068609

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
 
Loading Advertisement...
20081112-EE-VQP-44