Page 1 of 1
How to use "answer" to get user info like name? - Solved
Posted: Sat Nov 30, 2013 2:35 pm
by DR White
How can I use "answer" command to get user info like their name?
Only responses I see for "answer" command, is for user to click on a button. I need user to be able to type a little text.
Is it possible?
Thanks,
David
Re: How use "answer" to get user info like name?
Posted: Sat Nov 30, 2013 2:41 pm
by Klaus
Hi David,
just "ask" the user
Code: Select all
...
ask "What is your name?"
put it into tName
## User cancelled or did not type anything
if tName = empty then
exit to top
end if
## Now do whatever you like with tName
...
Best
Klaus
Re: How use "answer" to get user info like name?
Posted: Sat Nov 30, 2013 3:05 pm
by DR White
Klaus,
That works perfectly!
I was embarrassed to ask such a simple question, but when I went to the dictionary, all it referred to was user clicking on buttons.
You have really been a tremendous help in my learning to use LC!
Thanks,
David
Re: How use "answer" to get user info like name?
Posted: Sat Nov 30, 2013 3:23 pm
by Klaus
Hi David,
DR White wrote:You have really been a tremendous help in my learning to use LC!
I learned Livecode (its grandpa Metacard) the hard way without internet access in 1999,
so I could not ask anybody, just with TRY and ERROR
So I know the VERY steep learning curve of Livecode and like to help wherever I can
Best
Klaus