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
CODE PROJECT For Those Who Code
  • Home
  • Articles
  • FAQ
Community
  1. Home
  2. General Programming
  3. C / C++ / MFC
  4. SetWindowText problem - please look at that

SetWindowText problem - please look at that

Scheduled Pinned Locked Moved C / C++ / MFC
helptutorialquestion
8 Posts 6 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.
  • L Offline
    L Offline
    Lost User
    wrote on last edited by
    #1

    Can anybody help in this problem: There's an edit control - hwnd_edit. SetWindowText(hwnd_edit, "A line #1\nHere goes next line"); I need to do this: |-------------------| |A line #1 | |Here goes next line| | | | | |-------------------| Bus what's up? I see the following: |---------------------------------| |A line #1[]Here goes next line | | | | | |---------------------------------| [] is a small square How to deal with it?

    J 1 Reply Last reply
    0
    • L Lost User

      Can anybody help in this problem: There's an edit control - hwnd_edit. SetWindowText(hwnd_edit, "A line #1\nHere goes next line"); I need to do this: |-------------------| |A line #1 | |Here goes next line| | | | | |-------------------| Bus what's up? I see the following: |---------------------------------| |A line #1[]Here goes next line | | | | | |---------------------------------| [] is a small square How to deal with it?

      J Offline
      J Offline
      jmkhael
      wrote on last edited by
      #2

      Try a \r\n Make sure that the style multiline is checked Papa while (TRUE) Papa.WillLove ( Bebe ) ;

      I 1 Reply Last reply
      0
      • J jmkhael

        Try a \r\n Make sure that the style multiline is checked Papa while (TRUE) Papa.WillLove ( Bebe ) ;

        I Offline
        I Offline
        Igor Mihailov
        wrote on last edited by
        #3

        \n\r doesn't work - now there are two squares instead of CR LF. Multiline is certainly checked XPiS

        D J B 3 Replies Last reply
        0
        • I Igor Mihailov

          \n\r doesn't work - now there are two squares instead of CR LF. Multiline is certainly checked XPiS

          D Offline
          D Offline
          David Crow
          wrote on last edited by
          #4

          XPiS wrote: \n\r doesn't work It's important that you use \r\n (not \n\r) as was prescribed.


          "When I was born I was so surprised that I didn't talk for a year and a half." - Gracie Allen

          1 Reply Last reply
          0
          • I Igor Mihailov

            \n\r doesn't work - now there are two squares instead of CR LF. Multiline is certainly checked XPiS

            J Offline
            J Offline
            Jaime Stuardo
            wrote on last edited by
            #5

            Try \r\n, or even \r allone. Jaime

            1 Reply Last reply
            0
            • I Igor Mihailov

              \n\r doesn't work - now there are two squares instead of CR LF. Multiline is certainly checked XPiS

              B Offline
              B Offline
              bikram singh
              wrote on last edited by
              #6

              As far as I know, nothing like that will cause a multil-line title bar. Simply because Windows is meant to be user-friendly (read: consistent). I dont think using owner-draw for the title bar can accomplish multi-line title bars either. I suggest u change your strategy and display the required data in an appropriate place. Again, one of the reasons Windows is popular is because of the GUI consistency it maintains. Bikram Singh

              D 1 Reply Last reply
              0
              • B bikram singh

                As far as I know, nothing like that will cause a multil-line title bar. Simply because Windows is meant to be user-friendly (read: consistent). I dont think using owner-draw for the title bar can accomplish multi-line title bars either. I suggest u change your strategy and display the required data in an appropriate place. Again, one of the reasons Windows is popular is because of the GUI consistency it maintains. Bikram Singh

                D Offline
                D Offline
                David Crow
                wrote on last edited by
                #7

                Where is there mention of a multi-line title bar? Unless the OP changed his post, he wanted a multi-line edit box. Yes?


                "When I was born I was so surprised that I didn't talk for a year and a half." - Gracie Allen

                B 1 Reply Last reply
                0
                • D David Crow

                  Where is there mention of a multi-line title bar? Unless the OP changed his post, he wanted a multi-line edit box. Yes?


                  "When I was born I was so surprised that I didn't talk for a year and a half." - Gracie Allen

                  B Offline
                  B Offline
                  bikram singh
                  wrote on last edited by
                  #8

                  X| sorry ! my mistake! :rolleyes: Bikram Singh

                  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