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 / C++ / MFC
  4. SetWindowText Error

SetWindowText Error

Scheduled Pinned Locked Moved C / C++ / MFC
help
16 Posts 5 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.
  • H Hamid Taebi

    TCHAR buffer[50]; long a=20; _ltoa(a,buffer,10); status->m_TOTAL_WORDS.SetWindowText(buffer);_**


    **_

    whitesky


    V Offline
    V Offline
    VinayCool
    wrote on last edited by
    #6

    Hi WhiteSky, Can u please also tell me how to change it int to char ?? TCHAR buffer1[50]; int f=INDX.getTotalFiles(); _ltoa(f,buffer,10); status->m_TOTAL_FILES.SetWindowText(buffer1);

    H E 2 Replies Last reply
    0
    • V VinayCool

      Hi WhiteSky, Can u please also tell me how to change it int to char ?? TCHAR buffer1[50]; int f=INDX.getTotalFiles(); _ltoa(f,buffer,10); status->m_TOTAL_FILES.SetWindowText(buffer1);

      H Offline
      H Offline
      Hamid Taebi
      wrote on last edited by
      #7

      very simple _ltoa(f,buffer,10); to itoa(f,buffer,10);_**


      **_

      whitesky


      V 1 Reply Last reply
      0
      • V VinayCool

        Hi WhiteSky, Can u please also tell me how to change it int to char ?? TCHAR buffer1[50]; int f=INDX.getTotalFiles(); _ltoa(f,buffer,10); status->m_TOTAL_FILES.SetWindowText(buffer1);

        E Offline
        E Offline
        Eytukan
        wrote on last edited by
        #8

        vinaycool wrote:

        Can u please also tell me how to change it int to char ??

        _ltoa


        --[V]--

        [My Current Status]

        H L 2 Replies Last reply
        0
        • E Eytukan

          vinaycool wrote:

          Can u please also tell me how to change it int to char ??

          _ltoa


          --[V]--

          [My Current Status]

          H Offline
          H Offline
          Hamid Taebi
          wrote on last edited by
          #9

          Hi VuNic _ltoa or itoa_**


          **_

          whitesky


          E 1 Reply Last reply
          0
          • E Eytukan

            vinaycool wrote:

            Can u please also tell me how to change it int to char ??

            _ltoa


            --[V]--

            [My Current Status]

            L Offline
            L Offline
            Laxman Auti
            wrote on last edited by
            #10

            _ltoa - Convert a long integer to a string. _itoa - Convert an integer to a string Knock out 'T' from CAN'T , You 'CAN' if you think you 'CAN' :cool:

            E 1 Reply Last reply
            0
            • H Hamid Taebi

              very simple _ltoa(f,buffer,10); to itoa(f,buffer,10);_**


              **_

              whitesky


              V Offline
              V Offline
              VinayCool
              wrote on last edited by
              #11

              Yes its working thanks a lot.

              1 Reply Last reply
              0
              • H Hamid Taebi

                Hi VuNic _ltoa or itoa_**


                **_

                whitesky


                E Offline
                E Offline
                Eytukan
                wrote on last edited by
                #12

                Can u please also tell me how to change it int to char ?? TCHAR buffer1[50]; int f=INDX.getTotalFiles(); _ltoa(f,buffer,10); status->m_TOTAL_FILES.SetWindowText(buffer1); Oops, I misunderstood his question. I thought he was asking about the line that does the conversion.


                --[V]--

                [My Current Status]

                H 1 Reply Last reply
                0
                • L Laxman Auti

                  _ltoa - Convert a long integer to a string. _itoa - Convert an integer to a string Knock out 'T' from CAN'T , You 'CAN' if you think you 'CAN' :cool:

                  E Offline
                  E Offline
                  Eytukan
                  wrote on last edited by
                  #13

                  pleast look at my reply to whitesky. And Btw, you can still use ltoa for converting ints to chars. int is not something totally different from long. but Only the size ;)


                  --[V]--

                  [My Current Status]

                  L 1 Reply Last reply
                  0
                  • E Eytukan

                    pleast look at my reply to whitesky. And Btw, you can still use ltoa for converting ints to chars. int is not something totally different from long. but Only the size ;)


                    --[V]--

                    [My Current Status]

                    L Offline
                    L Offline
                    Laxman Auti
                    wrote on last edited by
                    #14

                    Due to the differences in size of long and int C++ provides the seperate functions :) Knock out 'T' from CAN'T , You 'CAN' if you think you 'CAN' :cool:

                    E 1 Reply Last reply
                    0
                    • L Laxman Auti

                      Due to the differences in size of long and int C++ provides the seperate functions :) Knock out 'T' from CAN'T , You 'CAN' if you think you 'CAN' :cool:

                      E Offline
                      E Offline
                      Eytukan
                      wrote on last edited by
                      #15

                      ;P :-D


                      --[V]--

                      [My Current Status]

                      1 Reply Last reply
                      0
                      • E Eytukan

                        Can u please also tell me how to change it int to char ?? TCHAR buffer1[50]; int f=INDX.getTotalFiles(); _ltoa(f,buffer,10); status->m_TOTAL_FILES.SetWindowText(buffer1); Oops, I misunderstood his question. I thought he was asking about the line that does the conversion.


                        --[V]--

                        [My Current Status]

                        H Offline
                        H Offline
                        Hamid Taebi
                        wrote on last edited by
                        #16

                        yes:)_**


                        **_

                        whitesky


                        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