Got a LiveCode personal license? Are you a beginner, hobbyist or educator that's new to LiveCode? This forum is the place to go for help getting started. Welcome!
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller
-
lemodizon
- Posts: 219
- Joined: Thu Apr 05, 2018 3:33 pm
Post
by lemodizon » Wed Jan 19, 2022 3:26 am
Hi everyone,
Good day.
How to do this in livecode see below the picture.
here's my code
Code: Select all
on mouseUp
put fld "OrderNumber" into tForReleaseOrder
put tForReleaseOrder & cr after fld "ForCollectFld"
end mouseUp
-
Attachments
-

Last edited by
lemodizon on Mon May 23, 2022 9:23 am, edited 1 time in total.
Thank you & God Bless Everyone
Regards,
lemodizon
-
richmond62
- Livecode Opensource Backer

- Posts: 10097
- Joined: Fri Feb 19, 2010 10:17 am
Post
by richmond62 » Wed Jan 19, 2022 8:28 am
Do you mean you want COLUMNS in your field?
-
lemodizon
- Posts: 219
- Joined: Thu Apr 05, 2018 3:33 pm
Post
by lemodizon » Wed Jan 19, 2022 8:50 am
Hi richmond62,
kinda like that but the twist here after the last number display which is "70". it will create another column and display other numbers.
Thanks richmond62.
Thank you & God Bless Everyone
Regards,
lemodizon
-
Klaus
- Posts: 14192
- Joined: Sat Apr 08, 2006 8:41 am
-
Contact:
Post
by Klaus » Wed Jan 19, 2022 10:49 am
Hi Lemodizon,
why not set a tabstop and add new columns with a TAB to the same field?
Code: Select all
...
repeat with i = 1 to the num of lines of fld 1
put TAB & your_value_here after line i of fld 1
end repeat
...
Et voila, columns!

Know what I mean?
Best
Klaus
-
richmond62
- Livecode Opensource Backer

- Posts: 10097
- Joined: Fri Feb 19, 2010 10:17 am
Post
by richmond62 » Wed Jan 19, 2022 3:32 pm
Sans voila!
Because:
-
-
The result is
ROWS, and
NOT COLUMNS.
-
Klaus
- Posts: 14192
- Joined: Sat Apr 08, 2006 8:41 am
-
Contact:
Post
by Klaus » Wed Jan 19, 2022 3:44 pm
row = line!
So your example shows 13 rows with 4 columns.
-
richmond62
- Livecode Opensource Backer

- Posts: 10097
- Joined: Fri Feb 19, 2010 10:17 am
Post
by richmond62 » Wed Jan 19, 2022 3:53 pm
-
My recent attempt, based on your suggestion, does NOT result in what Lemuel wants.
This is what he wants:
-
-
Mockup made in LibreOffice.
-
Klaus
- Posts: 14192
- Joined: Sat Apr 08, 2006 8:41 am
-
Contact:
Post
by Klaus » Wed Jan 19, 2022 4:29 pm
I know and only wanted to show how to create another "column"
in an existing field containing text already.
-
richmond62
- Livecode Opensource Backer

- Posts: 10097
- Joined: Fri Feb 19, 2010 10:17 am
Post
by richmond62 » Wed Jan 19, 2022 5:31 pm
Aha.
I wonder exactly how one can do what Lemuel wants?
-
Klaus
- Posts: 14192
- Joined: Sat Apr 08, 2006 8:41 am
-
Contact:
Post
by Klaus » Wed Jan 19, 2022 6:25 pm
Lemodizon,
do your numbers come from ONE field and you want them to display in columns in another field
or do you have several fields that you want to display in different columns in the same field?
Best
Klaus
-
jacque
- VIP Livecode Opensource Backer

- Posts: 7390
- Joined: Sat Apr 08, 2006 8:31 pm
-
Contact:
Post
by jacque » Wed Jan 19, 2022 6:35 pm
The easiest way would be to group three fields and scroll the group. Get the number of lines in the data and div by 3. Put lines 1 to x into fld 1, the next set of x lines into fld 2 and the final set into fld 3.
If only one field is required then put the first set into the field, then repeat for the next set putting a tab before the value after each line in the field. Do the same for the third set.
Jacqueline Landman Gay | jacque at hyperactivesw dot com
HyperActive Software | http://www.hyperactivesw.com
-
lemodizon
- Posts: 219
- Joined: Thu Apr 05, 2018 3:33 pm
Post
by lemodizon » Thu Jan 20, 2022 1:08 am
Klaus wrote: ↑Wed Jan 19, 2022 6:25 pm
Lemodizon,
do your numbers come from ONE field and you want them to display in columns in another field
or do you have several fields that you want to display in different columns in the same field?
Best
Klaus
Hi Klaus,
Yes it come from ONE field only. in my picture after i entered the number 70 it will create a column or tab near the number 150 but using only one filed.
-
Attachments
-

Thank you & God Bless Everyone
Regards,
lemodizon
-
Klaus
- Posts: 14192
- Joined: Sat Apr 08, 2006 8:41 am
-
Contact:
Post
by Klaus » Thu Jan 20, 2022 11:39 am
Hi lemodizon,
in my picture after i entered the number 70 it will create a column or tab near the number 150 but using only one field.
YOU entered? I thought this should be done completely via script?
So you have fixed values (70, 30, 60) after which the "column break" should happen?
Or any other "rule" for this?
And maybe you can post the content of that source field here, so we could experiment a bit?
Best
Klaus
-
lemodizon
- Posts: 219
- Joined: Thu Apr 05, 2018 3:33 pm
Post
by lemodizon » Thu Jan 20, 2022 1:57 pm
Klaus wrote: ↑Thu Jan 20, 2022 11:39 am
Hi lemodizon,
in my picture after i entered the number 70 it will create a column or tab near the number 150 but using only one field.
YOU entered? I thought this should be done completely via script?
So you have fixed values (70, 30, 60) after which the "column break" should happen?
Or any other "rule" for this?
And maybe you can post the content of that source field here, so we could experiment a bit?
Best
Klaus
Hi Klaus,
Good day.
Sorry this is the sample stack picture that i'm practicing. it has a enter button.
Code: Select all
on mouseUp
if fld "numberFld" is empty then
beep
Answer error "Please enter a Number. Thanks!"
else
put fld "numberFld" into tMyNumber
put tMyNumber & cr after fld "ForReleasingFld"
put empty into fld "numberFld"
end if
end mouseUp
-
Attachments
-

Thank you & God Bless Everyone
Regards,
lemodizon
-
Klaus
- Posts: 14192
- Joined: Sat Apr 08, 2006 8:41 am
-
Contact:
Post
by Klaus » Thu Jan 20, 2022 2:06 pm
We need more info, so I repeat:
So you have fixed values (70, 30, 60) after which the "column break" should happen?
Or any other "rule" for this?
And maybe you can post the content of that source field here, so we could experiment a bit?