4
Answers

Converting strings to enumerators

Simon Horton

Simon Horton

16y
2.5k
1

This is my latest obstacle:

So far I have:

Console.Write("Enter player's position: ");
string sPosition = Console.ReadLine();

I have already defined a position enumerator. How do I convert sPosition into my enumerator?
I want to put Convert.ToEnum or Enum.parse.

Answers (4)