I’m not sure if this work, does it needs any fixs?
And the app variable characters is a list that contains special characters like (@!#%$)
The does contain
block checks for the existence of a text string within another text string. For example:
• does “darn!” contain “!” returns TRUE
• does “darn!” contain “!@#%” returns FALSE
The in text find first occurrence of text
returns a number representing the location of the searched for string in the target string, or zero if not found. For example:
• in text “darn!” find first occurrence of text “!” returns 5
• in text “darn!” find first occurrence of text “!@#%” returns 0
So to check for multiple invalid characters, you’ll need to loop through the letters in the Password input's Text
to check if app variable Characters
contains them.
Thanks will do, so far i don’t know if it works but visually it does.
Your blocks will determine if the password the user types in contains a zero (“0”). Try it and you’ll see.
How can i loop, could you explain the blocks needed to do so?
So i just found out that no my code didnt work, i was working on other things.
Here’s how I would do it:
Put your text input’s text block or variable block where it says “word”. The delimited string is blank (“”). The loop variable j will contain each letter on the input text.
So i did what you told me, and what should i put in the delimiter text? I never really used that block. i imagine it the special characters or no?
The delimiter should be blank. If you wanted to make a list from text that contained a delimiter such as “one,two,three” then you would add the delimiter (in this case a comma “,”) to split those words into separate list items.
Ohhh i see, so the item “j” is the make list from text now i should do does “@!%#” contains j?
Yes, that’s right.
It worked like a charm, thanks!
And by the way, it worked but the things loops itself, let me send you a screenshot of what happening and where it looping (the text is looping itself when i tried submitting)
Can you post a link to your project? It’s hard to troubleshoot without all of the blocks.