Text Split with Space

c#, split, string

Solution

You don't need to specify a whitespace character for `Split` as that's the default if no characters are passed (or if `null` is used). `Split()` is the same as saying `Split(new char[0]);` due to the params overloaded method.

string input = @"C:\pagefile.sys 128 256";
string[] splitString = input.Split();
label1.Text = splitString[0];
label2.Text = splitString[1];
label3.Text = splitString[2];

Problem

I have this Line `C:\pagefile.sys 128 256` and i need to get the value example: ``` label1.text = C:\pagefile.sys label2.Text = 128; label3.text = 256; ``` all values are variable, it is possible?

Original source