setImageResources - I would like to add a string. Possible somehow?
<pre><code>public void correctLetter(String Letter, int pos){
    if(letter.equals("a")){ 
          ImageView image = images[pos];
          image.setImageResource(R.drawable.a);
          image.setVisibility(ImageView.VISIBLE); 
    }
</code></pre>

<p>At the moment i got a method looking like this. But, when i got 26 letters, thats going to be a lot of ifs.</p>

<p>Anyone got an idea how i can change that? I tried doing something like this, but the setImageResource required int anyways.</p>

<pre><code>public void correctLetter(String letter, int pos) {
        char newLetter = letter.toCharArray()[0];
        String startS = "R.drawable." + letter;
        startS += Character.toString(newLetter);
        ImageView image = images[pos];
        image.setImageResource(startS);
        image.setVisibility(ImageView.VISIBLE);
}
</code></pre>
