What is the difference between a regular string and a verbatim string?

A verbatim string is one that does not need to be escaped, like a filename:

string myFileName = "C:\\myfolder\\myfile.txt";

would be

string myFileName = @"C:\myfolder\myfile.txt";

The @ symbol means to read that string literally, and don’t interpret control characters otherwise.

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)