Simultaneously scrolling text vertically in two fields

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

dunbarx
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 9723
Joined: Wed May 06, 2009 2:28 pm
Location: New York, NY

Re: Simultaneously scrolling text vertically in two fields

Post by dunbarx » Mon Sep 25, 2023 9:25 pm

Dan,

Again, I saw that you had a solution to your problem. I went off into another track. It never occurred to me you would see my post as anything but what others called it, reminiscing. This sort of thing happens on this forum, who's members know each other, mainly, and which is generally friendly and easy going.

If you thought I was offering you yet another possible way forward, and since you do not have the long history that others here do, then I guess I do indeed understand your confusion. But it was no more than that.

And again, it was not I that first assumed (incorrectly, I see) that you were young. Hypercard was discontinued twenty years ago, and many new users here, quite able ones, in fact, have never heard of it. So I agree that just because you are new to xTalk, it does not mean you are young. But the replies you see show you that others here understood.

Please do not take this for anything more than what is was, a casual conversation engendered by and specifically related to your topic, but going back to olden times.

Craig
Last edited by dunbarx on Mon Sep 25, 2023 9:27 pm, edited 1 time in total.

jiml
Posts: 336
Joined: Sat Dec 09, 2006 1:27 am
Location: Los Angeles

Re: Simultaneously scrolling text vertically in two fields

Post by jiml » Mon Sep 25, 2023 9:26 pm

have two text fields on a card, fld 1 and fld 2. Each has its vertical scroll bar showing because there is text in each. Field 1 (f1) has one number on each line: 1 to 20. Field (f2) has a letter of the alphabet on each line: a to t. I want to be able to scroll both fields simultaneously
Does it absolutely need to be two fields?
Just One Field.livecode.zip
(1.23 KiB) Downloaded 64 times
Jim Lambert

dunbarx
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 9723
Joined: Wed May 06, 2009 2:28 pm
Location: New York, NY

Re: Simultaneously scrolling text vertically in two fields

Post by dunbarx » Mon Sep 25, 2023 9:31 pm

Hi.

I would definitely not use two fields. One will do just fine for your purpose and will be far easier to manage.

Have you ever used a table field? This is really just a standard field with certain properties. It is naturally tab and return delimited, and is simple to maintain. You could also use an ordinary scrolling field, with the two "parts" of your data separated by, say, a space or tab, whatever you think works best.

Then to access the "parts" of any line is simple. Use whatever delimiter makes sense, spaces or tabs in the above example.

Craig

dunbarx
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 9723
Joined: Wed May 06, 2009 2:28 pm
Location: New York, NY

Re: Simultaneously scrolling text vertically in two fields

Post by dunbarx » Mon Sep 25, 2023 9:33 pm

Jim.

I just now saw that it was you, and not another query on this subject. I happen to know for a fact that you do not need the advice I just gave, to, well, nobody. :D

Craig

scott_morrow
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 29
Joined: Tue Jun 27, 2006 8:35 pm
Location: Bellingham, WA USA
Contact:

Re: Simultaneously scrolling text vertically in two fields

Post by scott_morrow » Tue Sep 26, 2023 12:31 am

Hello Dan,
I'm glad that you got the problem solved. I have found that one of the great things about LiveCode is the community. Getting help with a problems is invariably met with cheerful optimism and great ideas. If also occasional reminiscing about the "good old days" :)
Elementary Software
...now with 20% less chalk dust!

richmond62
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 9444
Joined: Fri Feb 19, 2010 10:17 am
Location: Bulgaria

Re: Simultaneously scrolling text vertically in two fields

Post by richmond62 » Tue Sep 26, 2023 10:09 am

Dan. = confused old guy
My father (who died at 86) lived in a different country to me, and, at 78 decided he wanted to learn 'computer programming' [I have never been quite sure what that means: either nothing, or so much that it also doesn't mean very much].

So we started on LiveCode; always remembering something my Granny [Dad's Mum] said: "A picture is worth a thousand words." My father was subjected to 7 years of remote instruction - to the extent that he graduated with a Bachelor's degree in computer programming at the age of 85!

So, should you get bogged down, Please, Please,do not hesitate to contact me, either inwith a thread like this, privately via the forums, or via my email address ( richmondmathewson@gmail.com ) . . . I can at least claim great skill in helping a 'confused old guy' become even more confused. 8)

If you don't feel 'funny' about FaceBook you are also welcome to poke around here:

https://www.facebook.com/profile.php?id=100063797865443

https://www.facebook.com/RMOXTclasses/

dunbarx
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 9723
Joined: Wed May 06, 2009 2:28 pm
Location: New York, NY

Re: Simultaneously scrolling text vertically in two fields

Post by dunbarx » Tue Sep 26, 2023 2:34 pm

Dan.

Did you see the section of this thread just a few posts above about the one field/two field thing? There is fodder for discussion there, never mind my mistaking the original intent of it.

Craig

urbaud
Posts: 118
Joined: Tue Feb 24, 2009 12:10 am
Location: Victoria, BC, Canada

Re: Simultaneously scrolling text vertically in two fields

Post by urbaud » Tue Sep 26, 2023 9:11 pm

Hi Craig,
I re-read all of the posts after my initial post and now I get why you went off on a tangent. It was scott_morrow who suggested the scrollbarDrag message. I didn’t get it at the time, but as you said, HC had no such message back in the day. I remember hearing about HC, but never did any thing with it. Back in the day, or as you put it, back in the Pleistocene, I was messing around with Microsoft Basic and the “old” Visual Basic, and I happened upon RunTime Revolution by chance. Tried it and stuck with it. Had you mentioned or indicated why you “went off script” I think I would have understood at the time what you were doing. And by the way, I’ve never used a table field. But I think I’ll look into it.

And scott_morrow, again, thanks for your help.

And richmond62 thanks for the info about both fields and more importantly for your offer for help in the future if I get bogged down. I really appreciate the offer because at times in the past when I’ve had a problem I’d wish that I could contact someone who could help rather than go on the forum. So thank you so much for your offer of help—I have noted your email in my contacts.

And jmburnod thanks for the info on the same text properties.

And Klaus thanks for helping me “stay young” in my mind, if not in body.

And stam thanks for helping me understand why Craig wrote what he wrote.

And jiml I did download “Just One Field” and ran it. It is like what I wanted to do, so thanks. I’ll use it.

So, to all of you who responded to my post, thank you so very much. I have learned several things. If I come on the forum in the future I hope I’ll remember this conversation we have had—but maybe I won’t so bear with me.

Dan
urbaud

stam
Posts: 2729
Joined: Sun Jun 04, 2006 9:39 pm
Location: London, UK

Re: Simultaneously scrolling text vertically in two fields

Post by stam » Tue Sep 26, 2023 9:17 pm

It’s never wrong to ask here if you get stuck. Almost always someone (probably many) will chime in with advice in the best spirit possible.

One peculiarity with the forums is the ramdom tangents as you’ve witnessed but actually some find that a good thing ;)

Post Reply

Return to “Getting Started with LiveCode - Complete Beginners”