Removing line breaks using C#

前端 未结 5 1986
时光取名叫无心
时光取名叫无心 2021-02-20 03:55

I am getting a string from database field named \'Description\' and it has line breaks. It looks like this:


Header of Items

Description goes here.This the

5条回答
  •  生来不讨喜
    2021-02-20 04:44

    Your issue is the @ symbol. It is not necessary in this case.

    You want

    comments.Replace("\r\n", "");
    

提交回复
热议问题