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. How much data can be stored by CString Type varible

How much data can be stored by CString Type varible

Scheduled Pinned Locked Moved C / C++ / MFC
help
7 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.
  • R Offline
    R Offline
    rajneshmalik
    wrote on last edited by
    #1

    hi I want to know How much data can be stored by CString Type varible.My actual problem is I want to show the data of file in edit box if file is of 120 mb all the data is shown by the command GetDlgItem(ID of edit box)->SetWindowText(CString Type Variable); but is file is big all data is not shown

    CPalliniC T J 3 Replies Last reply
    0
    • R rajneshmalik

      hi I want to know How much data can be stored by CString Type varible.My actual problem is I want to show the data of file in edit box if file is of 120 mb all the data is shown by the command GetDlgItem(ID of edit box)->SetWindowText(CString Type Variable); but is file is big all data is not shown

      CPalliniC Offline
      CPalliniC Offline
      CPallini
      wrote on last edited by
      #2

      rajneshmalik wrote:

      I want to know How much data can be stored by CString Type varible.

      Probably depends of your system memory since CString allocates the internal buffer on the heap, I suppose. but

      rajneshmalik wrote:

      I want to show the data of file in edit box if file is of 120 mb all the data is shown by the command

      does the above really make sense?

      If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler. -- Alfonso the Wise, 13th Century King of Castile.
      [my articles]

      In testa che avete, signor di Ceprano?

      1 Reply Last reply
      0
      • R rajneshmalik

        hi I want to know How much data can be stored by CString Type varible.My actual problem is I want to show the data of file in edit box if file is of 120 mb all the data is shown by the command GetDlgItem(ID of edit box)->SetWindowText(CString Type Variable); but is file is big all data is not shown

        T Offline
        T Offline
        toxcct
        wrote on last edited by
        #3

        theoretically, up to 2GB.

        [VisualCalc][Binary Guide][CommDialogs] | [Forums Guidelines]

        1 Reply Last reply
        0
        • R rajneshmalik

          hi I want to know How much data can be stored by CString Type varible.My actual problem is I want to show the data of file in edit box if file is of 120 mb all the data is shown by the command GetDlgItem(ID of edit box)->SetWindowText(CString Type Variable); but is file is big all data is not shown

          J Offline
          J Offline
          Jimmanuel
          wrote on last edited by
          #4

          What about the text limit of the CEdit control? The default limit is something like 64K iirc, have you set the limit of that large enough to view 120mb worth of text?

          D 1 Reply Last reply
          0
          • J Jimmanuel

            What about the text limit of the CEdit control? The default limit is something like 64K iirc, have you set the limit of that large enough to view 120mb worth of text?

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

            Jimmanuel wrote:

            What about the text limit of the CEdit control? The default limit is something like 64K iirc...

            It depends on the OS. Win98 and before had a 64KB limit.

            "Normal is getting dressed in clothes that you buy for work and driving through traffic in a car that you are still paying for, in order to get to the job you need to pay for the clothes and the car and the house you leave vacant all day so you can afford to live in it." - Ellen Goodman

            "To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne

            P 1 Reply Last reply
            0
            • D David Crow

              Jimmanuel wrote:

              What about the text limit of the CEdit control? The default limit is something like 64K iirc...

              It depends on the OS. Win98 and before had a 64KB limit.

              "Normal is getting dressed in clothes that you buy for work and driving through traffic in a car that you are still paying for, in order to get to the job you need to pay for the clothes and the car and the house you leave vacant all day so you can afford to live in it." - Ellen Goodman

              "To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne

              P Offline
              P Offline
              pierre_ribery
              wrote on last edited by
              #6

              Then use a CRichEdit control. That being said, it is horrible design to put 120Mb into an edit control

              D 1 Reply Last reply
              0
              • P pierre_ribery

                Then use a CRichEdit control. That being said, it is horrible design to put 120Mb into an edit control

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

                Perhaps you meant to reply to the OP.

                "Normal is getting dressed in clothes that you buy for work and driving through traffic in a car that you are still paying for, in order to get to the job you need to pay for the clothes and the car and the house you leave vacant all day so you can afford to live in it." - Ellen Goodman

                "To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne

                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