Welcome to %s forums

BrainModular Users Forum

Login Register

Empty strings

I need help on a Patch
Post Reply
LevraiBernardo
Site Admin
Posts: 110
Contact:

Unread post by LevraiBernardo » 15 Mar 2010, 07:15

I have a problem with textfields : When an empty string is entered, nothing happens in the wire (I mean there was a string in the text field output. If I enter an empty string, the old one is still there instead of a null string). So how to check if a textfield is empty ?

User avatar
nay-seven
Site Admin
Posts: 5684
Location: rennes France
Contact:

Unread post by nay-seven » 15 Mar 2010, 08:07

can you explain a little more wich module you use and the order..?

usually when there's an empty string you can see:
[large]""[/large][large][/large]
in the text field

User avatar
senso
Site Admin
Posts: 4424
Location: France
Contact:

Unread post by senso » 15 Mar 2010, 08:28

you're right, the empty string is considered as a NULL event in Usine.
It can be a pb in your case, let me think about it.

User avatar
senso
Site Admin
Posts: 4424
Location: France
Contact:

Unread post by senso » 15 Mar 2010, 10:59

oups I forgot something
To check if a string is empty just use get array size module. If size = 0 then the string is empty

LevraiBernardo
Site Admin
Posts: 110
Contact:

Unread post by LevraiBernardo » 15 Mar 2010, 11:18

Yes, Senso, I tried that, but it doesn't work anymore : If you link a text field to a get array size, type "Hello" in the field. Array size is 5. Fine. Then, type an empty string in the field, the array size is still 5 (and [Array] in "Array In" pin becomes red, to show it's an empty array).

User avatar
senso
Site Admin
Posts: 4424
Location: France
Contact:

Unread post by senso » 15 Mar 2010, 12:54

ok.
I understand why it works on my system.
[large]I'll post an update very soon.[/large]


Post Reply

Who is online

Users browsing this forum: No registered users and 15 guests