how do i set text alignment in live code using a button

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: Klaus, FourthWorld, heatherlaine, kevinmiller

Post Reply
LiveyMcLivecode
Posts: 1
Joined: Wed Nov 23, 2016 8:56 pm

how do i set text alignment in live code using a button

Post by LiveyMcLivecode » Wed Nov 23, 2016 9:00 pm

Hey, i need help with my project where i need to have a button reset the text alignment of a filed to center after its already been changed

Klaus
Posts: 10477
Joined: Sat Apr 08, 2006 8:41 am
Location: Germany
Contact:

Re: how do i set text alignment in live code using a button

Post by Klaus » Thu Nov 24, 2016 1:57 pm

Hi LiveyMcLivecode,

1. welcome to the forum! :D

2. Check "textalign" in the dictionary, which is far better than its reputation!):
...
set the textalign of fld XYZ to center
...

3. Will move this thread to the "Bginner" forum, since this is not an "App Building Course" question, not related ot any "Clock" 8)

4. Please hceck these stacks to learn more about the very basics of Livecode:
http://www.hyperactivesw.com/revscriptc ... ences.html


Best

Klaus

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

Re: how do i set text alignment in live code using a button

Post by dunbarx » Thu Nov 24, 2016 3:35 pm

Very upbeat name, Lively.

Always go to the dictionary first. You will very soon, after you gain more experience, know that the word "text" has "got" to have something to do with your current question. In this particular case, there will be a lot of entries, but if you scan them you would have run across "textAlign" on your own, as Klaus directed you. And then you would have drilled into that property, and seen that it is just what you needed.

Craig Newman

Post Reply

Return to “Getting Started with LiveCode - Complete Beginners”