ユーザーが入力するブラウザのテキストボックスがあります。入力した内容を改行で分割するために、次のことを試みています。次のことを試しましたが、うまくいきませんでした。エラーが発生するか、分割されません。
content.Split("\n", StringSplitOptions.None) < gives me an error Error The best overloaded method match for 'string.Split(params char[])' has some invalid arguments
content.Split('\n', StringSplitOptions.None) < gives an error: The best overloaded method match for 'string.Split(params char[])' has some invalid arguments
content.Split(new[] { Environment.NewLine }, StringSplitOptions.None) < doesn't split as needed. When I look at the source in debugger I just see \n characters.
content.Split(new[] { "\r\n" }, StringSplitOptions.None) < doesn't split as needed. When I look at the source in debugger I just see \n characters.
誰かが私に何ができるか提案できますか?