Change
try { myNum = Integer.parseInt(myString.getText().toString());} catch(NumberFormatException nfe) {
to
try { myNum = Integer.parseInt(myString);} catch(NumberFormatException nfe) {
It's already a string? Remove the getText() call.
int myNum = 0;try { myNum = Integer.parseInt(myString);} catch(NumberFormatException nfe) { // Handle parse error.}
You just need to write the line of code to convert your string to int.
int convertedVal = Integer.parseInt(YOUR STR);