Remove / Validate Line Breaks

Hey --

Line breaks are causing me alot of trouble and I need to somehow either validate them, so they can't submit until they take them out, or prep the sql string and just remove them automatically. But how would you say line break? Are there different types?

Who is Participating?
Here is one of I'm sure many way to remove line breaks

Dim str as string = "some text with line breaks.."
str = str.replace(vbCrLf, string.empty).replace(vbLf, string.empty)
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.