We help IT Professionals succeed at work.

VB6 - Max Lines in VB6 TextBox

feesu
feesu asked
on
3,537 Views
Last Modified: 2012-05-05
Hi,
Is there a maximum limit for lines in a normal vb6 textbox?
Comment
Watch Question

Jai STech Arch

Commented:
if you have the MULTI LINE property then there is no actual limit
but your application will become slower as more data gets added to your control
Guy Hengel [angelIII / a3]Billing Engineer
CERTIFIED EXPERT
Most Valuable Expert 2014
Top Expert 2009

Commented:
the limit is not the number of lines, but the number of characters, which is 64K, AFAIK.

Author

Commented:
I've got an application that receives tcpip feed. I display them in a text box. It actually gets slow and freezes after a day or work, cuz i don't turn it off. It has to keep running. The amount of data is very huge. Do i empty the content every certain number of lines or every certain text.length? Or what do you recommend?
Jai STech Arch

Commented:
instead of a textbox...wnhy not use a rich text box or someother control which has the capability to hold more data...

if you are not really thinking of displaying the data...you can also save it in a file...which is much faster
Guy Hengel [angelIII / a3]Billing Engineer
CERTIFIED EXPERT
Most Valuable Expert 2014
Top Expert 2009

Commented:
>Do i empty the content every certain number of lines or every certain text.length? Or what do you recommend?
yes, you can do that.
as the "number of lines" is not that easy with a textbox, I do reduce based on the size in such applications...

Author

Commented:
I don't need to save the data. Just to show it to user. I am already saving it in my code to a database. The text box is there to show the user what's happening.

What is my check going to be like? What is the length that i should reset the text box when i reach to?
Jai STech Arch

Commented:
if Len(textbox.text) > 1000 then textbox.text =""
Billing Engineer
CERTIFIED EXPERT
Most Valuable Expert 2014
Top Expert 2009
Commented:
Unlock this solution and get a sample of our free trial.
(No credit card required)
UNLOCK SOLUTION

Author

Commented:
Thanks!

Gain unlimited access to on-demand training courses with an Experts Exchange subscription.

Get Access
Why Experts Exchange?

Experts Exchange always has the answer, or at the least points me in the correct direction! It is like having another employee that is extremely experienced.

Jim Murphy
Programmer at Smart IT Solutions

When asked, what has been your best career decision?

Deciding to stick with EE.

Mohamed Asif
Technical Department Head

Being involved with EE helped me to grow personally and professionally.

Carl Webster
CTP, Sr Infrastructure Consultant
Empower Your Career
Did You Know?

We've partnered with two important charities to provide clean water and computer science education to those who need it most. READ MORE

Ask ANY Question

Connect with Certified Experts to gain insight and support on specific technology challenges including:

  • Troubleshooting
  • Research
  • Professional Opinions
Unlock the solution to this question.
Thanks for using Experts Exchange.

Please provide your email to receive a sample view!

*This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

OR

Please enter a first name

Please enter a last name

8+ characters (letters, numbers, and a symbol)

By clicking, you agree to the Terms of Use and Privacy Policy.