Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C#
  4. How to change new line in textBox

How to change new line in textBox

Scheduled Pinned Locked Moved C#
questionhelptutorial
3 Posts 3 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • W Offline
    W Offline
    wk_vigorous
    wrote on last edited by
    #1

    Hi, guys. I set the control textBox as Multiline true. And I want change the text line with such way"Contents.\n in the box". But "\n" didn't change a new line instead of displaying an error character. What 's the reson? And how can I can realize changing a new in my code? Thanks a lot vigorous

    L 1 Reply Last reply
    0
    • W wk_vigorous

      Hi, guys. I set the control textBox as Multiline true. And I want change the text line with such way"Contents.\n in the box". But "\n" didn't change a new line instead of displaying an error character. What 's the reson? And how can I can realize changing a new in my code? Thanks a lot vigorous

      L Offline
      L Offline
      Lost User
      wrote on last edited by
      #2

      wk_vigorous wrote: And I want change the text line with such way"Contents.\n in the box". But "\n" didn't change a new line instead of displaying an error character. Try \n\r wk_vigorous wrote: And how can I can realize changing a new in my code? That makes no sense. If you want to find out when the text changes, you can handle the TextChanged event. Aaron Eldreth TheCollective4.com My Articles While much is too strange to be believed, Nothing is too strange to have happened. - T. Hardy

      R 1 Reply Last reply
      0
      • L Lost User

        wk_vigorous wrote: And I want change the text line with such way"Contents.\n in the box". But "\n" didn't change a new line instead of displaying an error character. Try \n\r wk_vigorous wrote: And how can I can realize changing a new in my code? That makes no sense. If you want to find out when the text changes, you can handle the TextChanged event. Aaron Eldreth TheCollective4.com My Articles While much is too strange to be believed, Nothing is too strange to have happened. - T. Hardy

        R Offline
        R Offline
        Rulala
        wrote on last edited by
        #3

        Try \r\n , please. I used \n\r before , but it didn't change. I don't know the cause. hello ALL..^^

        1 Reply Last reply
        0
        Reply
        • Reply as topic
        Log in to reply
        • Oldest to Newest
        • Newest to Oldest
        • Most Votes


        • Login

        • Don't have an account? Register

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • World
        • Users
        • Groups