Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

is there a command that checks how many strings are within an array as follow

Posted on 2008-10-14
2
Medium Priority
?
205 Views
Last Modified: 2013-12-17
is there a command that would check how many items (in this example -- word items) there are in the following array :: GlobalVars._inputWords
private static string[] inputWords;
 
        public static string[] _inputWords
        {
            get { return inputWords; }
            set { inputWords = value; }
        }
 
public static void removeAllNonAlphaTextFromString(string inputText)
        {
            GlobalVars._inputWords =
                inputText.Split(new char[] { ' ', ',', ';', '.', '-', '/', '|', '\\',
                                             '%', '#', '@', '!', '~', '$', '^', '(',
                                             ')', '+', '[', ']', '{', '}', '"', ':', 
                                             '<', '>', '?',  '\r', '\n', '*' }, StringSplitOptions.RemoveEmptyEntries);        
 
                foreach (string inputWord in GlobalVars._inputWords)
                    Console.WriteLine(inputWord);       
        }

Open in new window

0
Comment
Question by:amillyard
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 55

Accepted Solution

by:
Jaime Olivares earned 2000 total points
ID: 22716836
GlobalVars._inputWords.Length
0
 

Author Closing Comment

by:amillyard
ID: 31506122
jaime_olivares:  excellent -- many thanks :-)
0

Featured Post

Hire Technology Freelancers with Gigs

Work with freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely, and get projects done right.

Question has a verified solution.

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

IP addresses can be stored in a database in any of several ways.  These ways may vary based on the volume of the data.  I was dealing with quite a large amount of data for user authentication purpose, and needed a way to minimize the storage.   …
Wouldn’t it be nice if you could test whether an element is contained in an array by using a Contains method just like the one available on List objects? Wouldn’t it be good if you could write code like this? (CODE) In .NET 3.5, this is possible…
Video by: ITPro.TV
In this episode Don builds upon the troubleshooting techniques by demonstrating how to properly monitor a vSphere deployment to detect problems before they occur. He begins the show using tools found within the vSphere suite as ends the show demonst…
In this video, Percona Solution Engineer Rick Golba discuss how (and why) you implement high availability in a database environment. To discuss how Percona Consulting can help with your design and architecture needs for your database and infrastr…

618 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