Page 1 of 1

multiple text entries

Posted: Sat Jan 21, 2012 4:23 pm
by KennyR
Hello again everyone! Sorry I feel like I am burning up the boards with stupid questions but here it goes anyway...

I have been searching the forum and help files but can't seem to find anything about keeping text entries from being overwritten when a new entry is made. What I mean is this...I have a card that allows a user to enter a First name, Last Name and some text. Then when the user saves the entries ,it puts those entries into another scrolling text field. This works great, but what happens is when they make another entry and save it, the prior text is overwritten by the new text. Is there a way that when the text of the user is submitted, the program determines if there is already text in the field and places it below the prior entry instead of overwriting it? I would like it to look like this for multiple entries....

(Entry #1)
First Name Last Name
Text of the user

(Entry #2)
First Name Last Name
Text of the user

and so on....

Re: multiple text entries

Posted: Sat Jan 21, 2012 4:42 pm
by Dixie
Kenny...

Try something like this...

Code: Select all

on mouseUp
   put fld "firstName" & tab & fld "lastName" & cr after fld 3
end mouseUp
This will put your new entry into a new line in the 3rd field where you are collecting the names...

Hope it helps

Dixie

Re: multiple text entries

Posted: Sat Jan 21, 2012 5:29 pm
by KennyR
Thank you for your response, but this does not solve this issue with a new text entry being overwritten.... I think your code is for spacing out the entries to resemble a certain format....that I have figured out....my problem is after the first entry is made by the user i.e. "First Name, Last Name, some text" the entries are put into another scrolling text field, which is fine, but when the user goes to make another text entry and save that one, it overwrites the last entry. I would like to have the previous entry preserved on its own line(s) and a new entry placed below it....I hope I have not made this too confusing...

Re: multiple text entries

Posted: Sat Jan 21, 2012 7:22 pm
by dunbarx
Hi.

I assume you are putting the new text "into" your target field. Read up on this as well as the "after" keyword in the dictionary. And ALL its "see also" terms.

These gadgets are among the most useful and powerful in the language if you are fooling around with text. They form the foundation of what is know as "chunking". Nobody has ever made better tools.

Craig Newman

Re: multiple text entries

Posted: Sat Jan 21, 2012 7:23 pm
by Dixie
Kenny...

That's 'exactly' what that script does !... it places what has been entered in fld 1 & fld 2 on a new line in fld 3... look at what is in the line... a carriage return to put it on a new line in fld 3, and putting it after whatever else is in fld 3

be well

Dixie

Re: multiple text entries

Posted: Sat Jan 21, 2012 9:59 pm
by KennyR
Thanks guys...I read about the keywords and it fixed the issue....also after looking at Dixie's previous post I now realize what she was saying....I didn't understand what the code was actually doing...well I guess you gotta learn somehow! Thanks again for everyone's help!