Question: I'm getting a message being sent to my program from an external device and I need to check what the string message is.

What is the process I need to do to this?

What I'm trying to do is this: 

```
string read_in_value;

void ReadInMessage(string message)
{
  read_in_value = message;
  if( read_in_value == /* the message value being sent in */ )
  {
      // DO SSTUFF
  }
}

```

I know normally it would be a case of putting `if (read_in_value == message)` but I need to check the actual message that is being read in. The value being sent could be one of two things I need to check against.

Answer: 
if you have multiple values,these is way to check the string :

```
List<string> answervalue=new List<string>;
answervalue.ADD("firstthing")
answervalue.ADD("secondthing")…………

if(answervalue.contains(/*the message value being send it*/)
{
//do some thing
}

```
```
if( read_in_value == "firstthing" ||  read_in_value == "secondthing" )
{
    // DO SSTUFF
}

```

or

```
void ReadInMessage(string message)
{
  if( message == "firstthing" || message == "secondthing" )
  {
      // DO SSTUFF
  }
}

```