How can I remove double quotes from a string

时间:2017-08-04 12:28:11

标签: c#

I have a variable "currntdate" of type string

The value of the variable is "'2017-08-03'" (quotes included)

Now i want to remove the double quotes ".

How can I do that in C#?

1 个答案:

答案 0 :(得分:2)

Supposed you have

var currntDate =  @"""'2017-08-03'""";

Just use

currntDate = currntDate.Replace("\"","");