I don't seem to find an answer for this in C#, so here it goes:
I have a string:
string slug = "123,456";
And I want to end up with two strings that I can then parse to integers:
Number1 = "123";
Number2 = "456";
I don't seem to find an answer for this in C#, so here it goes:
I have a string:
string slug = "123,456";
And I want to end up with two strings that I can then parse to integers:
Number1 = "123";
Number2 = "456";
var numbers = slug.Split(",");
var Number1 = int.Parse(numbers[0])
var Number2 = int.Parse(numbers[1])