I am new to app inventor. I have an app where a user inputs their name into a text box...ex JOHN. I want to use this name to then say Welcome John once the name is typed. How would I go about doing this?
- A textbox
- For display the message with a name there's a lot of ways and components to do that.
- I don't want you to interpret it as a bad thing, something personal, or that we don't care about helping (Quite the opposite).
But I recommend starting with the basic tutorials and documentation as you go along; It is not only because the answer to your question comes out there, but it also allows us to "speak the same language" because we would have the same glossary of words, terms and concepts.
Now we could answer you with 100% certainty and 300 examples of how to do it, even give you the complete project and ready to compile.
But you wouldn't understand a single word of what we would say to you.
In the Designer, pull in
- a Textbox
- A Label
- A Button
- (optional) a Text to Speech component (look further down in the Designer)
In the Blocks Editor,
Look through the Button1 blocks pallette for the Button1.Click event, and drag it onto the Blocks Workspace.
Look in the Label1 blocks for the block that sets Label1.Text and pull it into the Button1.Click event.
Pull out a JOIN block from the text bloxks pallette, and plug it into the right of the Label1.Text block.
Press the ' key on the keyboard and type Welcome, then press Enter. A red text block should appear with that text. Drag it into the first socket of the JOIN block.
Look in the Textbox1 pallette, and drag Textbox1.Text into the second socket.
Either start the Companion app or Build the app and install it on your phone. It's ready to go.
For extra credit, drag a block from the Speech to Text component into the button Click event to announce the Label.Text contents.