cerebalbore
Technical User
Hi all,
I've got an issue with an application and carriage return characters, and after researching and Googling haven't found a solution.
In the application a user enters the first comment, then when a subsequent comment is added to the existing, the existing comment(string) is separated using string split on chr(10), the second comment is added and a separator is entered as chr(10) between them, and so on.
This should eventually build up a string like this:
"[1]:Blah Blah blah" & chr(10) & "[2]:blah blah blah" & chr(10) & "[3]:Blah blah blah"
This does two things - allows the datagrid view to structure each comment on separate lines and gives us a character to separate the comments from the string, which allows us to build functionality to amend comments.
The problem comes when a user presses the enter key when entering a comment. It adds VbCrLf on the end of each line, so the string eventually looks like this:
"[1]:Blah " & chr(10) & chr(13) & "blah blah" & chr(10) & "[3]:Blah blah" & chr(10)
Notice how the comments aren't in order?? And how it's almost impossible to split this string into the original comments?
So I guess my question is, is there a character I can use that will act like a carriage return (which isn't 13 or 10), and that can't be entered via the keyboard?
I'm such a noob
I've got an issue with an application and carriage return characters, and after researching and Googling haven't found a solution.
In the application a user enters the first comment, then when a subsequent comment is added to the existing, the existing comment(string) is separated using string split on chr(10), the second comment is added and a separator is entered as chr(10) between them, and so on.
This should eventually build up a string like this:
"[1]:Blah Blah blah" & chr(10) & "[2]:blah blah blah" & chr(10) & "[3]:Blah blah blah"
This does two things - allows the datagrid view to structure each comment on separate lines and gives us a character to separate the comments from the string, which allows us to build functionality to amend comments.
The problem comes when a user presses the enter key when entering a comment. It adds VbCrLf on the end of each line, so the string eventually looks like this:
"[1]:Blah " & chr(10) & chr(13) & "blah blah" & chr(10) & "[3]:Blah blah" & chr(10)
Notice how the comments aren't in order?? And how it's almost impossible to split this string into the original comments?
So I guess my question is, is there a character I can use that will act like a carriage return (which isn't 13 or 10), and that can't be entered via the keyboard?
I'm such a noob