Source: C # Escape Character Summary
Escape Character \ · a special character constant; · starts with a backslash "\", followed by one or more characters. · It has a specific meaning. It is called "escape" because it is different from the original meaning of the character. · It is mainly used to indicate controls that are not easily expressed with general characters Code . · Its function is to eliminate the original meaning of the characters that follow it. Some common character combinations are used to replace some special characters, because their combinations change the meaning of the original character representation, therefore, it is called "escape". You can use visible characters to represent invisible characters. For example, '\ n' indicates line feed. textbox. TEXT = "you are \" Genius \ ", haha! "Show what? Display: You are a common escape character of "genius" Haha and Its Meaning escape character meaning \ 'single quotation mark character \ "single quotation mark character \ backslash character" \ "\ 0 null character (null) \ A bell \ B back grid \ f go to paper feed \ n line feed \ r press enter \ t jump horizontally to the next tabulation position \ v vertical hop grid (vertical tabulation) ASCII contains some non-printable characters, such as line breaks and bell rings. These characters must be directly written to the ASCII value for output. These ASCII characters do not have any regularity, are less readable and hard to remember, for this reason, people have invented escape characters to replace ASCII values, so as to get rid of the disadvantages of ASCII and facilitate people's use. In C #, what is @? For example, string svspath = @ "" + this. openfiledialog1.filename; what does it mean? --------------- in C #, "C: \ Temp" indicates that the path is c: \ Temp and @ "C: \ Temp" indicates C: \ Temp. Therefore, @ should be used to ignore escape characters. are you sure you understand this correctly ????????????? What should I do if I want to display "\ t? Response. Write ("\" \ t \ "); display result:" \ t "Write A VB.netProgram I forgot the escape double quotation marks of VB.net and expressed it with \ ", but an error occurred! As I used to write C # code, I finally figured out that in VB.net, I used to use two double quotes to represent "". Now, only these are posted. Please try again later! C # escape character name
\ 'Single quotes
\ "Double quotation marks
\ Backslash
\ 0 null characters
\ A exclamation point
\ B Return
\ F form feed
\ N New Line
\ R press ENTER
\ T horizontal Tab
\ V vertical tab ------------ VB.net escape character name "": "member constant equivalent description javascrlf vbcrlf CHR (13) + CHR (10) carriage return/line feed character combination. (Controlchars. CRLF) Cr vbcr CHR (13) carriage return. Lf vblf CHR (10) line break. Newline vbnewline CHR (13) + CHR (10) newline. The most standard. the all-new, C #, and VB.net libraries in the. NET class library can automatically adapt to environment changes: environment. newline example: dim str1 as string = "you" & Environment. newline & "" C # escape characters
meaning of escape characters \ n carriage return newline \ t jump horizontally to the next tabulation position \ v vertical hop grid \ B unggle \ r carriage return \ f go to paper form \ reverse diagonal Line Character "\" \ 'single quotation mark character \ A bell \ DDD 1 ~ The three octal characters \ xhh 1 ~ The characters represented by the two-digit hexadecimal number are output in the text box as escape characters in \ r \ n C: \ n --------------------------- newline \ r ----------------------- press enter \ t character tab \ B character return \ f character form \ 0 character empty symbol \ "character double quotation marks \ ''' Character single quotation marks \ lead reverse quotation marks there is also a special slash, that is, @. As long as the @ sign is added before the statement, it means that all the following @ characters including escape characters do not undergo escape operations.