TheSwamp

Code Red => .NET => Topic started by: Bryco on November 01, 2018, 04:13:05 PM

Title: b-b becomes b - b
Post by: Bryco on November 01, 2018, 04:13:05 PM
Is there a setting that will stop vs15 and vs17 from adding spaces to anything pasted w/ a "-"
Title: Re: b-b becomes b - b
Post by: gile on November 01, 2018, 06:03:49 PM
Hi,

I think this is not due to vs2015 or 2017, this is due to the fact you cannot use the '-' character in a variable name.
With C#, a variable name must start with either a letter, an underscore character (_), or the at symbol (@). Subsequent characters may only be letters, underscore characters, or numbers.
If you need to paste a string containing a '-', you have to enter a double quote before pasting it.
Title: Re: b-b becomes b - b
Post by: Bryco on November 02, 2018, 01:58:11 PM
Ty Gile that explains it perfectly