Reputation: 9429
I have this VB code that I am converting for someone, but he didn't comment it, so what does it mean
Dim Arguments As String = path & "\" & fs & ".freeze" & " ls"
Upvotes: 3
Views: 342
Reputation: 12864
private string _arguments = Path.Combine(path, fs + ".freeze") + " ls";
This should work.
Upvotes: 1
Reputation: 612794
The &
operator in Visual Basic is used to concatenate strings. In C# the concatenation operator is +
and so the direct translation is
string Arguments = path + @"\" + fs + ".freeze" + " ls";
Better in my view would be to use Path.Combine
:
string Arguments = Path.Combine(path, fs + ".freeze") + " ls";
Upvotes: 9
Reputation: 1499790
That's just string concatenation:
string arguments = path + @"\" + fs + ".freeze" + " ls";
Upvotes: 3