The @ can also be used to escape a keyword so you can use it as an
identifier.
public void MyMethod(string @string) // You now have a variable
called string
{
//...
}
Now, whether you should ever actually do this is debatable at best. It's
useful for things like machine-generated code, where you might be generating
a class where parameter names are derived from a source that doesn't have
the same keywords as C# (i.e., xsd.exe).
"Jon Skeet [C# MVP]" <skeet@pobox.com> wrote in message
news:MPG.1d841dbe772edda098c661@msnews.microsoft.c om...[color=blue]
> Water Cooler v2 <wtr_clr@yahoo.com> wrote:[color=green]
>> I see this @ character a lot in front of C# strings. I searched the
>> documentation online but coult not come up with the page that explains
>> this symbol. What is it used for?[/color]
>
> See
http://www.pobox.com/~skeet/csharp/s....html#literals
>
> --
> Jon Skeet - <skeet@pobox.com>
>
http://www.pobox.com/~skeet
> If replying to the group, please do not mail me too[/color]