Sign in to follow this  
Followers 0
lyledg

Limit of characters using GUICtrlCreateEdit?

6 posts in this topic

I have a dos batch script that pipes it's results out using the Stdout routine to a GUICtrlCreateEdit control. Problem is that after a few seconds of running this, the output just stops even thought the script continue's to run.

Is there a limit on the the amount of characters GUICtrlCreateEdit can take? If not, how could I can it set it to receive an infinite amount of characters??

Cheers

Share this post


Link to post
Share on other sites



#2 ·  Posted (edited)

as far as i know there is no one, but you can easily ask for the number of letters with taking them to a string and then ask for the stringlength... then you make a condition if letters > 50... now you always set the editbox minus the last letter if a key is pressed and the box is focused...

Edited by Lord_Doominik

Share this post


Link to post
Share on other sites

#3 ·  Posted (edited)

Thanks for this response, but does this approach not defeat the object of having Stdout, or am I not understanding your post correctly?

Basically, my current Stdout routine to an edit box works...it's just the amount of characters that it returns hit's a limit and stops..Piping the output to a string value seems a bit tedious...

Edited by lyledg

Share this post


Link to post
Share on other sites

#4 ·  Posted (edited)

ahm, i'm sry, but can you explain me what you mean with "tedious"? i tryed to translated it, but there are many different meanings... some like boring, some like difficult o.O.

putting the output to a string should work fine... here an example:

$editboxstring = String(GUICtrlRead($editbox)
$length = StringLen($editboxstring)

If $length > 50 Then
   ...
EndIf
Edited by Lord_Doominik

Share this post


Link to post
Share on other sites

I have a dos batch script that pipes it's results out using the Stdout routine to a GUICtrlCreateEdit control. Problem is that after a few seconds of running this, the output just stops even thought the script continue's to run.

Is there a limit on the the amount of characters GUICtrlCreateEdit can take? If not, how could I can it set it to receive an infinite amount of characters??

Cheers

By default (on Win XP at least) an editbox has a 32kb buffer, this is a thread that talks about this plus a method of resizing the buffer.


Yes yes yes, there it was. Youth must go, ah yes. But youth is only being in a way like it might be an animal. No, it is not just being an animal so much as being like one of these malenky toys you viddy being sold in the streets, like little chellovecks made out of tin and with a spring inside and then a winding handle on the outside and you wind it up grrr grrr grrr and off it itties, like walking, O my brothers. But it itties in a straight line and bangs straight into things bang bang and it cannot help what it is doing. Being young is like being like one of these malenky machines.

Share this post


Link to post
Share on other sites

Dave F

Thank you VERY much for your input mate, your solution helped heaps and solved my problem...

Cheers

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0